From 433a1fada0d8091181e5c362c6d025382a40f994 Mon Sep 17 00:00:00 2001 From: Tianyi-W <107507036+Tianyi-W@users.noreply.github.com> Date: Fri, 29 Jul 2022 18:00:07 -0700 Subject: [PATCH] docs(dynamodb): the documentation is wrong around table encryption (#20938) ---- This pull request aims to resolve https://github.com/aws/aws-cdk/issues/16436. As mentioned in the issue, by default, no encryption is done, which is different from the documentation description. Now the documentation descriptions are updated around the table encryption as the default is for the Table to not be encrypted. Closes #16436 ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license* --- packages/@aws-cdk/aws-dynamodb/lib/table.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/packages/@aws-cdk/aws-dynamodb/lib/table.ts b/packages/@aws-cdk/aws-dynamodb/lib/table.ts index a3ebe5f61967e..f518ea9a4914a 100644 --- a/packages/@aws-cdk/aws-dynamodb/lib/table.ts +++ b/packages/@aws-cdk/aws-dynamodb/lib/table.ts @@ -188,7 +188,7 @@ export interface TableOptions extends SchemaOptions { * * This property cannot be set if `encryption` and/or `encryptionKey` is set. * - * @default - server-side encryption is enabled with an AWS owned customer master key + * @default - The table is encrypted with an encryption key managed by DynamoDB, and you are not charged any fee for using it. * * @deprecated This property is deprecated. In order to obtain the same behavior as * enabling this, set the `encryption` property to `TableEncryption.AWS_MANAGED` instead. @@ -213,7 +213,7 @@ export interface TableOptions extends SchemaOptions { * > using CDKv1, make sure the feature flag * > `@aws-cdk/aws-kms:defaultKeyPolicies` is set to `true` in your `cdk.json`. * - * @default - server-side encryption is enabled with an AWS owned customer master key + * @default - The table is encrypted with an encryption key managed by DynamoDB, and you are not charged any fee for using it. */ readonly encryption?: TableEncryption; @@ -224,6 +224,8 @@ export interface TableOptions extends SchemaOptions { * * @default - If `encryption` is set to `TableEncryption.CUSTOMER_MANAGED` and this * property is undefined, a new KMS key will be created and associated with this table. + * If `encryption` and this property are both undefined, then the table is encrypted with + * an encryption key managed by DynamoDB, and you are not charged any fee for using it. */ readonly encryptionKey?: kms.IKey;