@aws/nx-plugin-mcp 1.0.0-rc.42 → 1.0.0-rc.43

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -13,6 +13,7 @@ import RunGenerator from '@components/run-generator.astro';
13
13
  import GeneratorParameters from '@components/generator-parameters.astro';
14
14
  import NxCommands from '@components/nx-commands.astro';
15
15
  import Snippet from '@components/snippet.astro';
16
+ import OptionFilter from '@components/option-filter.astro';
16
17
 
17
18
  This generator creates a new Python relational database project backed by [Amazon Aurora](https://aws.amazon.com/rds/aurora/) (PostgreSQL or MySQL), [SQLModel](https://sqlmodel.tiangolo.com/) for data modelling, and [Alembic](https://alembic.sqlalchemy.org/) for schema migrations. It generates the application code and infrastructure needed to provision and manage a database using AWS CDK or Terraform, with declarative schema definition, automatic migration deployment, and a database client.
18
19
 
@@ -214,7 +215,15 @@ When using RDS Proxy, you do not need to configure the RDS CA bundle in the runt
214
215
 
215
216
  ### Logging and Monitoring
216
217
 
217
- <Snippet name="rdb/logging" />
218
+ <OptionFilter when={{ engine: 'postgres' }}>
219
+ <Snippet name="rdb/logging-postgres" />
220
+ </OptionFilter>
221
+
222
+ <OptionFilter when={{ engine: 'mysql' }}>
223
+ <Snippet name="rdb/logging-mysql" />
224
+ </OptionFilter>
225
+
226
+ <Snippet name="rdb/performance-insights" />
218
227
 
219
228
  ### Encryption Key Rotation
220
229
 
@@ -292,7 +292,15 @@ For more details, see the AWS Lambda [SSL/TLS requirements for Amazon RDS connec
292
292
 
293
293
  ### Logging and Monitoring
294
294
 
295
- <Snippet name="rdb/logging" />
295
+ <OptionFilter when={{ engine: 'postgres' }}>
296
+ <Snippet name="rdb/logging-postgres" />
297
+ </OptionFilter>
298
+
299
+ <OptionFilter when={{ engine: 'mysql' }}>
300
+ <Snippet name="rdb/logging-mysql" />
301
+ </OptionFilter>
302
+
303
+ <Snippet name="rdb/performance-insights" />
296
304
 
297
305
  ### Encryption Key Rotation
298
306
 
@@ -0,0 +1,5 @@
1
+ ---
2
+ title: MySQL Query Logging
3
+ ---
4
+
5
+ The `audit` and `error` logs are exported for [Aurora MySQL](https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/AuroraMySQL.Integrating.CloudWatch.html) — `general` and `slowquery` are deliberately excluded since they log full statement text, including DML values. [Advanced Auditing](https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/AuroraMySQL.Auditing.html) is scoped to connections and DDL (`server_audit_events=CONNECT,QUERY_DDL`), so statement parameter values are never logged.
@@ -0,0 +1,5 @@
1
+ ---
2
+ title: PostgreSQL Query Logging
3
+ ---
4
+
5
+ The `postgresql` log is exported for [Aurora PostgreSQL](https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/AuroraPostgreSQL.CloudWatch.html), with logging scoped to DDL statements only (`log_statement=ddl`) so statement parameter values are never logged — as long as each statement is sent on its own. `log_statement=ddl` logs the entire raw text of a multi-statement batch (e.g. a single `psql -c "a;b;c"` call) verbatim if any statement in it is DDL, including any DML values in that same batch.
@@ -0,0 +1,34 @@
1
+ ---
2
+ title: Performance Insights
3
+ ---
4
+ import Infrastructure from '@components/infrastructure.astro';
5
+
6
+ Performance Insights is enabled on the Aurora writer instance by default (encrypted with the cluster's KMS key). Aurora engine logs are also exported to [CloudWatch Logs](https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/USER_LogAccess.html) by default, configured to surface schema-level activity without leaking row data.
7
+
8
+ Disable log export per database if not required:
9
+
10
+ <Infrastructure>
11
+ <Fragment slot="cdk">
12
+
13
+ ```ts title="packages/infra/src/stacks/application-stack.ts"
14
+ import { MyDatabase } from ':my-scope/common-constructs';
15
+
16
+ const db = new MyDatabase(this, 'Db', {
17
+ ...
18
+ enableCloudwatchLogs: false,
19
+ enablePerformanceInsights: false,
20
+ });
21
+ ```
22
+ </Fragment>
23
+ <Fragment slot="terraform">
24
+
25
+ ```hcl title="packages/infra/src/main.tf"
26
+ module "my_database" {
27
+ source = "../../common/terraform/src/app/dbs/my-database"
28
+ ...
29
+ enable_cloudwatch_logs = false # disable if not required
30
+ enable_performance_insights = false # disable if not required
31
+ }
32
+ ```
33
+ </Fragment>
34
+ </Infrastructure>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aws/nx-plugin-mcp",
3
- "version": "1.0.0-rc.42",
3
+ "version": "1.0.0-rc.43",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/awslabs/nx-plugin-for-aws.git",
@@ -1,32 +0,0 @@
1
- ---
2
- title: Logging and Monitoring
3
- ---
4
- import Infrastructure from '@components/infrastructure.astro';
5
-
6
- Performance Insights is enabled on the Aurora writer instance by default (encrypted with the cluster's KMS key). You can also export the Aurora engine logs to [CloudWatch Logs](https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/USER_LogAccess.html) (`postgresql` for [Aurora PostgreSQL](https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/AuroraPostgreSQL.CloudWatch.html); `audit`, `error`, `general` and `slowquery` for [Aurora MySQL](https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/AuroraMySQL.Integrating.CloudWatch.html)). Enable log export per database:
7
-
8
- <Infrastructure>
9
- <Fragment slot="cdk">
10
-
11
- ```ts title="packages/infra/src/stacks/application-stack.ts"
12
- import { MyDatabase } from ':my-scope/common-constructs';
13
-
14
- const db = new MyDatabase(this, 'Db', {
15
- ...
16
- enableCloudwatchLogs: true,
17
- enablePerformanceInsights: false, // disable if not required
18
- });
19
- ```
20
- </Fragment>
21
- <Fragment slot="terraform">
22
-
23
- ```hcl title="packages/infra/src/main.tf"
24
- module "my_database" {
25
- source = "../../common/terraform/src/app/dbs/my-database"
26
- ...
27
- enable_cloudwatch_logs = true
28
- enable_performance_insights = false # disable if not required
29
- }
30
- ```
31
- </Fragment>
32
- </Infrastructure>