Skip to content

(aws-redshift): KmsKeyId uses KeyArn instead of KeyId #17032

Closed
@gkubes

Description

What is the problem?

When a Cluster is created the KmsKeyId property is built using the KeyArn instead of the KeyId.

Reproduction Steps

const encryptionKey = new kms.Key(this, "KMSKey", {
    enabled: true,
    enableKeyRotation: true
});

const wbrCluster = new redshift.Cluster(this, "WBRRedshiftCluster", {
    ...
    encrypted: true,
    encryptionKey: encryptionKey,
    
});

What did you expect to happen?

"KmsKeyId": {
  "Ref": "KMSKey"
},

or

"KmsKeyId": {
  "Fn::GetAtt": [
    "WBRDataKMSKey",
    "KeyId"
  ]
},

What actually happened?

"KmsKeyId": {
  "Fn::GetAtt": [
    "WBRDataKMSKey",
    "Arn"
  ]
},

CDK CLI Version

1.126.0

Framework Version

No response

Node.js Version

12.0

OS

Amazon Linux 2012

Language

Typescript

Language Version

No response

Other information

No response

Metadata

Assignees

No one assigned

    Labels

    @aws-cdk/aws-redshiftRelated to Amazon RedshiftbugThis issue is a bug.effort/smallSmall work item – less than a day of effortgood first issueRelated to contributions. See CONTRIBUTING.mdp1

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions