SchemaConfiguration

class aws_cdk.aws_kinesisfirehose.SchemaConfiguration(*args: Any, **kwargs)

Bases: object

Represents a schema configuration for Firehose S3 data record format conversion.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-kinesisfirehose-deliverystream-dataformatconversionconfiguration.html#cfn-kinesisfirehose-deliverystream-dataformatconversionconfiguration-schemaconfiguration

ExampleMetadata:

infused

Example:

# bucket: s3.Bucket
# schema_glue_table: glue.CfnTable

s3_destination = firehose.S3Bucket(bucket,
    data_format_conversion=firehose.DataFormatConversionProps(
        schema_configuration=firehose.SchemaConfiguration.from_cfn_table(schema_glue_table),
        input_format=firehose.InputFormat.OPENX_JSON,
        output_format=firehose.OutputFormat.PARQUET
    )
)

Methods

bind(scope, *, role)

Binds this Schema to the Destination, adding the necessary permissions to the Destination role.

Parameters:
  • scope (Construct)

  • role (IRole) – The IAM Role that will be used by the Delivery Stream for access to the Glue data catalog for record format conversion.

Return type:

SchemaConfigurationProperty

Static Methods

classmethod from_cfn_table(table, *, region=None, version_id=None)

Obtain schema configuration for data record format conversion from an aws_glue.CfnTable.

Parameters:
  • table (CfnTable)

  • region (Optional[str]) – The region of the database the table is in. Default: the region of the stack that contains the table reference is used

  • version_id (Optional[str]) – Specifies the table version for the output data schema. if set to LATEST, Firehose uses the most recent table version. This means that any updates to the table are automatically picked up. Default: LATEST

Return type:

SchemaConfiguration