Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CfnDeliveryStream.ExtendedS3DestinationConfigurationProperty: file_extension parameter does not exist #32154

Open
ayankowsky opened this issue Nov 15, 2024 · 3 comments
Assignees
Labels
documentation This is a problem with documentation. investigating This issue is being investigated and/or work is in progress to resolve the issue. p2 package/tools Related to AWS CDK Tools or CLI response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days.

Comments

@ayankowsky
Copy link

Describe the issue

Using the file_extension parameter results in an error.

TypeError: CfnDeliveryStream.ExtendedS3DestinationConfigurationProperty.__init__() got an unexpected keyword argument 'file_extension'

Links

https://docs.aws.amazon.com/cdk/api/v2/python/aws_cdk.aws_kinesisfirehose/CfnDeliveryStream.html#aws_cdk.aws_kinesisfirehose.CfnDeliveryStream.ExtendedS3DestinationConfigurationProperty

@ayankowsky ayankowsky added documentation This is a problem with documentation. needs-triage This issue or PR still needs to be triaged. labels Nov 15, 2024
@github-actions github-actions bot added the package/tools Related to AWS CDK Tools or CLI label Nov 15, 2024
@khushail khushail added investigating This issue is being investigated and/or work is in progress to resolve the issue. p2 and removed needs-triage This issue or PR still needs to be triaged. labels Nov 15, 2024
@khushail khushail self-assigned this Nov 15, 2024
@khushail
Copy link
Contributor

Hi @ayankowsky , thanks for reaching out. The cloudformation docs specify FileExtension as property under ExtendedS3Configuration -https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-kinesisfirehose-deliverystream-extendeds3destinationconfiguration.html#cfn-kinesisfirehose-deliverystream-extendeds3destinationconfiguration-fileextension.

Could you please share a minimum code snippet which can repro the error.
Thanks

@khushail khushail added response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days. and removed investigating This issue is being investigated and/or work is in progress to resolve the issue. labels Nov 15, 2024
Copy link

This issue has not received a response in a while. If you want to keep this issue open, please leave a comment below and auto-close will be canceled.

@github-actions github-actions bot added the closing-soon This issue will automatically close in 4 days unless further comments are made. label Nov 18, 2024
@ayankowsky
Copy link
Author

ayankowsky commented Nov 18, 2024

Creating any Firehose with an ExtendedS3DestinationConfigurationProperty that specifies a file_extension will recreate the error:

example_firehose = firehose.CfnDeliveryStream(
    self,
    "ExampleFirehose",
    delivery_stream_name="ExampleFirehose",
    delivery_stream_type="DirectPut",
    extended_s3_destination_configuration=firehose.CfnDeliveryStream.ExtendedS3DestinationConfigurationProperty(
        bucket_arn=example_bucket.bucket_arn,
        role_arn=example_firehose_role.role_arn,
        compression_format="GZIP",
        prefix="Example/",
        buffering_hints=firehose.CfnDeliveryStream.BufferingHintsProperty(
            interval_in_seconds=60,
            size_in_m_bs=64,
        ),
        file_extension=".json.gz",
        error_output_prefix="ErrorLogs/",
    ),
)

If you look at the ExtendedS3DestinationConfigurationProperty class init() function, you'll see file_extension is not a parameter, as the documentation suggests.

    class ExtendedS3DestinationConfigurationProperty:
        def __init__(
            self,
            *,
            bucket_arn: builtins.str,
            role_arn: builtins.str,
            buffering_hints: typing.Optional[typing.Union[_IResolvable_da3f097b, typing.Union["CfnDeliveryStream.BufferingHintsProperty", typing.Dict[builtins.str, typing.Any]]]] = None,
            cloud_watch_logging_options: typing.Optional[typing.Union[_IResolvable_da3f097b, typing.Union["CfnDeliveryStream.CloudWatchLoggingOptionsProperty", typing.Dict[builtins.str, typing.Any]]]] = None,
            compression_format: typing.Optional[builtins.str] = None,
            data_format_conversion_configuration: typing.Optional[typing.Union[_IResolvable_da3f097b, typing.Union["CfnDeliveryStream.DataFormatConversionConfigurationProperty", typing.Dict[builtins.str, typing.Any]]]] = None,
            dynamic_partitioning_configuration: typing.Optional[typing.Union[_IResolvable_da3f097b, typing.Union["CfnDeliveryStream.DynamicPartitioningConfigurationProperty", typing.Dict[builtins.str, typing.Any]]]] = None,
            encryption_configuration: typing.Optional[typing.Union[_IResolvable_da3f097b, typing.Union["CfnDeliveryStream.EncryptionConfigurationProperty", typing.Dict[builtins.str, typing.Any]]]] = None,
            error_output_prefix: typing.Optional[builtins.str] = None,
            prefix: typing.Optional[builtins.str] = None,
            processing_configuration: typing.Optional[typing.Union[_IResolvable_da3f097b, typing.Union["CfnDeliveryStream.ProcessingConfigurationProperty", typing.Dict[builtins.str, typing.Any]]]] = None,
            s3_backup_configuration: typing.Optional[typing.Union[_IResolvable_da3f097b, typing.Union["CfnDeliveryStream.S3DestinationConfigurationProperty", typing.Dict[builtins.str, typing.Any]]]] = None,
            s3_backup_mode: typing.Optional[builtins.str] = None,
        ) -> None:

This seems to be unintentionally left out from CDK, especially since CloudFormation supports this parameter, while CDK does not.

@khushail khushail added investigating This issue is being investigated and/or work is in progress to resolve the issue. and removed closing-soon This issue will automatically close in 4 days unless further comments are made. labels Nov 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation This is a problem with documentation. investigating This issue is being investigated and/or work is in progress to resolve the issue. p2 package/tools Related to AWS CDK Tools or CLI response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days.
Projects
None yet
Development

No branches or pull requests

2 participants