From 737508620b29f4034f13701557a2d7215333ab65 Mon Sep 17 00:00:00 2001 From: Gavin Zhang Date: Thu, 11 Jan 2024 15:12:14 -0800 Subject: [PATCH] Update readme --- packages/aws-cdk-lib/aws-rds/README.md | 6 ++++-- packages/aws-cdk-lib/aws-rds/lib/cluster.ts | 3 ++- packages/aws-cdk-lib/aws-rds/lib/instance.ts | 3 ++- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/packages/aws-cdk-lib/aws-rds/README.md b/packages/aws-cdk-lib/aws-rds/README.md index 28dbc3ba18f7d..0002cc58ffec5 100644 --- a/packages/aws-cdk-lib/aws-rds/README.md +++ b/packages/aws-cdk-lib/aws-rds/README.md @@ -959,7 +959,8 @@ const cluster = new rds.DatabaseCluster(this, 'Database', { // ... }); -// You can get the log group of a cluster +// When 'cloudwatchLogsExports' is set, each export value creates its own log group in DB cluster. +// Specify an export value to access its log group. const errorLogGroup = cluster.cloudwatchLogGroups['error']; const auditLogGroup = cluster.cloudwatchLogGroups.audit; @@ -974,7 +975,8 @@ const instance = new rds.DatabaseInstance(this, 'Instance', { // ... }); -// You can get the log group of a cluster +// When 'cloudwatchLogsExports' is set, each export value creates its own log group in DB instance. +// Specify an export value to access its log group. const errorLogGroup = instance.cloudwatchLogGroups['postgresql']; ``` diff --git a/packages/aws-cdk-lib/aws-rds/lib/cluster.ts b/packages/aws-cdk-lib/aws-rds/lib/cluster.ts index f4ad908846926..6047bc24781e9 100644 --- a/packages/aws-cdk-lib/aws-rds/lib/cluster.ts +++ b/packages/aws-cdk-lib/aws-rds/lib/cluster.ts @@ -503,7 +503,8 @@ abstract class DatabaseClusterNew extends DatabaseClusterBase { public readonly vpcSubnets?: ec2.SubnetSelection; /** - * The log groups created when cloudwatchLogsExports is set + * The log groups created when cloudwatchLogsExports is set. Each export value + * will create a separate log group. */ public readonly cloudwatchLogGroups: {[engine: string]: logs.ILogGroup}; diff --git a/packages/aws-cdk-lib/aws-rds/lib/instance.ts b/packages/aws-cdk-lib/aws-rds/lib/instance.ts index 8193a581ff5cb..31adc9a738a37 100644 --- a/packages/aws-cdk-lib/aws-rds/lib/instance.ts +++ b/packages/aws-cdk-lib/aws-rds/lib/instance.ts @@ -744,7 +744,8 @@ abstract class DatabaseInstanceNew extends DatabaseInstanceBase implements IData public readonly connections: ec2.Connections; /** - * The cloudwatch log groups created when cloudwatchLogsExports is set + * The log groups created when cloudwatchLogsExports is set. Each export value + * will create a separate log group. */ public readonly cloudwatchLogGroups: {[engine: string]: logs.ILogGroup};