OpenXJsonInputFormatProps
- class aws_cdk.aws_kinesisfirehose.OpenXJsonInputFormatProps(*, column_to_json_key_mappings=None, convert_dots_in_json_keys_to_underscores=None, lowercase_column_names=None)
Bases:
objectProps for OpenX JSON input format for data record format conversion.
- Parameters:
column_to_json_key_mappings (
Optional[Mapping[str,str]]) – Maps column names to JSON keys that aren’t identical to the column names. This is useful when the JSON contains keys that are Hive keywords. For example,timestampis a Hive keyword. If you have a JSON key namedtimestamp, set this parameter to{"ts": "timestamp"}to map this key to a column namedtsDefault: JSON keys are not renamedconvert_dots_in_json_keys_to_underscores (
Optional[bool]) – When set totrue, specifies that the names of the keys include dots and that you want Firehose to replace them with underscores. This is useful because Apache Hive does not allow dots in column names. For example, if the JSON contains a key whose name is “a.b”, you can define the column name to be “a_b” when using this option. Default:falselowercase_column_names (
Optional[bool]) – Whether the JSON keys should be lowercased when written as column names. Default:true
- ExampleMetadata:
infused
Example:
input_format = firehose.OpenXJsonInputFormat( lowercase_column_names=False, column_to_json_key_mappings={"ts": "timestamp"}, convert_dots_in_json_keys_to_underscores=True )
Attributes
- column_to_json_key_mappings
Maps column names to JSON keys that aren’t identical to the column names.
This is useful when the JSON contains keys that are Hive keywords. For example,
timestampis a Hive keyword. If you have a JSON key namedtimestamp, set this parameter to{"ts": "timestamp"}to map this key to a column namedts- Default:
JSON keys are not renamed
- convert_dots_in_json_keys_to_underscores
When set to
true, specifies that the names of the keys include dots and that you want Firehose to replace them with underscores.This is useful because Apache Hive does not allow dots in column names. For example, if the JSON contains a key whose name is “a.b”, you can define the column name to be “a_b” when using this option.
- Default:
false
- lowercase_column_names
Whether the JSON keys should be lowercased when written as column names.
- Default:
true