aws / aws-cdk

The AWS Cloud Development Kit is a framework for defining cloud infrastructure in code
https://aws.amazon.com/cdk
Apache License 2.0
11.61k stars 3.9k forks source link

❗ NOTICE(bedrock): AWS::Bedrock::DataSource L1 construct is missing `DataSourceConfiguration` property in latest version 2.154.0 #31183

Closed krokoko closed 1 month ago

krokoko commented 1 month ago

Please add your +1 👍 to let us know you have encountered this

Status:

RESOLVED Fixed in version 2.154.1

Overview:

v2.154.0 removes DataSourceConfiguration property from AWS::Bedrock::DataSource resource L1 construct.

Workaround:

Downgrade to v2.153.0

Solution:

Upgrade to >= v2.154.1

Related Issues:

N/A


ORIGINAL ISSUE DESCRIPTION

Describe the bug

https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_bedrock.CfnDataSource.html was updated with v2.154.0 However, it is missing a property which is available in cfn: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-bedrock-datasource.html The property is DataSourceConfiguration. The property is listed in the header of the cdk documentation, but not available in the example, construct props. This property was available in previous versions

Regression Issue

Last Known Working CDK Version

2.153

Expected Behavior

The property is available

Current Behavior

The property is not available, which makes the construct unusable

Reproduction Steps

use the latest cdk version 2.154.0

Possible Solution

No response

Additional Information/Context

No response

CDK CLI Version

2.154

Framework Version

No response

Node.js Version

20

OS

MacOs

Language

TypeScript, Python, .NET, Java, Go

Language Version

No response

Other information

No response

ashishdhingra commented 1 month ago
pahud commented 1 month ago

confirmed a regression by checking bedrock.generated.d.ts:

CfnDataSourceProps in 2.154.0

export interface CfnDataSourceProps {
    /**
     * The data deletion policy for the data source.
     *
     * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-bedrock-datasource.html#cfn-bedrock-datasource-datadeletionpolicy
     */
    readonly dataDeletionPolicy?: string;
    /**
     * The description of the data source.
     *
     * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-bedrock-datasource.html#cfn-bedrock-datasource-description
     */
    readonly description?: string;
    /**
     * The unique identifier of the knowledge base to which the data source belongs.
     *
     * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-bedrock-datasource.html#cfn-bedrock-datasource-knowledgebaseid
     */
    readonly knowledgeBaseId: string;
    /**
     * The name of the data source.
     *
     * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-bedrock-datasource.html#cfn-bedrock-datasource-name
     */
    readonly name: string;
    /**
     * Contains details about the configuration of the server-side encryption.
     *
     * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-bedrock-datasource.html#cfn-bedrock-datasource-serversideencryptionconfiguration
     */
    readonly serverSideEncryptionConfiguration?: cdk.IResolvable | CfnDataSource.ServerSideEncryptionConfigurationProperty;
    /**
     * Contains details about how to ingest the documents in the data source.
     *
     * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-bedrock-datasource.html#cfn-bedrock-datasource-vectoringestionconfiguration
     */
    readonly vectorIngestionConfiguration?: cdk.IResolvable | CfnDataSource.VectorIngestionConfigurationProperty;
}

CfnDataSourceProps in 2.153.0

export interface CfnDataSourceProps {
    /**
     * The data deletion policy for the data source.
     *
     * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-bedrock-datasource.html#cfn-bedrock-datasource-datadeletionpolicy
     */
    readonly dataDeletionPolicy?: string;
    /**
     * The connection configuration for the data source.
     *
     * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-bedrock-datasource.html#cfn-bedrock-datasource-datasourceconfiguration
     */
    readonly dataSourceConfiguration: CfnDataSource.DataSourceConfigurationProperty | cdk.IResolvable;
    /**
     * The description of the data source.
     *
     * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-bedrock-datasource.html#cfn-bedrock-datasource-description
     */
    readonly description?: string;
    /**
     * The unique identifier of the knowledge base to which the data source belongs.
     *
     * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-bedrock-datasource.html#cfn-bedrock-datasource-knowledgebaseid
     */
    readonly knowledgeBaseId: string;
    /**
     * The name of the data source.
     *
     * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-bedrock-datasource.html#cfn-bedrock-datasource-name
     */
    readonly name: string;
    /**
     * Contains details about the configuration of the server-side encryption.
     *
     * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-bedrock-datasource.html#cfn-bedrock-datasource-serversideencryptionconfiguration
     */
    readonly serverSideEncryptionConfiguration?: cdk.IResolvable | CfnDataSource.ServerSideEncryptionConfigurationProperty;
    /**
     * Contains details about how to ingest the documents in the data source.
     *
     * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-bedrock-datasource.html#cfn-bedrock-datasource-vectoringestionconfiguration
     */
    readonly vectorIngestionConfiguration?: cdk.IResolvable | CfnDataSource.VectorIngestionConfigurationProperty;
}
github-actions[bot] commented 1 month ago

Comments on closed issues and PRs are hard for our team to see. If you need help, please open a new issue that references this one.

krokoko commented 1 month ago

Thank you for the quick fix ! :)

github-actions[bot] commented 1 month ago

Comments on closed issues and PRs are hard for our team to see. If you need help, please open a new issue that references this one.