@aws/nx-plugin-mcp 1.0.0-rc.81 → 1.0.0-rc.82

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.
@@ -146,16 +146,7 @@ resource "aws_vpc_security_group_egress_rule" "agent_to_database" {
146
146
  }
147
147
  ```
148
148
 
149
- `appconfig_application_id`/`appconfig_application_arn` come from the shared <Link path="guides/runtime-config">runtime configuration</Link> AppConfig application declared once in your root module, not from the database module. Include the `database` namespace when instantiating it so the database module's runtime configuration entry is deployed:
150
-
151
- ```hcl title="packages/infra/src/main.tf"
152
- module "runtime_config_appconfig" {
153
- source = "../../common/terraform/src/core/runtime-config/appconfig"
154
-
155
- application_name = "my-app-runtime-config"
156
- namespaces = ["connection", "agentcore", "database"]
157
- }
158
- ```
149
+ `appconfig_application_id`/`appconfig_application_arn` come from the shared <Link path="guides/runtime-config">runtime configuration</Link> AppConfig application declared once in your root module, not from the database module. That application exposes the `database` namespace by default, so the database module's runtime configuration entry is deployed without further configuration.
159
150
 
160
151
  </Fragment>
161
152
  </Infrastructure>
@@ -163,16 +163,7 @@ resource "aws_vpc_security_group_egress_rule" "api_to_database" {
163
163
 
164
164
  Deploy the API Lambda functions into **private subnets with egress**, not private isolated subnets. `appconfig_application_id`/`appconfig_application_arn` come from the shared <Link path="guides/runtime-config">runtime configuration</Link> AppConfig application declared once in your root module, not from the database module — passing them sets `RUNTIME_CONFIG_APP_ID` on the Lambda functions and grants them read access to the application.
165
165
 
166
- The AppConfig application must expose the `database` namespace so the database module's runtime configuration entry is deployed. Include it in the `namespaces` when instantiating the `runtime-config/appconfig` module:
167
-
168
- ```hcl title="packages/infra/src/main.tf"
169
- module "runtime_config_appconfig" {
170
- source = "../../common/terraform/src/core/runtime-config/appconfig"
171
-
172
- application_name = "my-app-runtime-config"
173
- namespaces = ["connection", "agentcore", "database"]
174
- }
175
- ```
166
+ The AppConfig application exposes the `database` namespace by default, so the database module's runtime configuration entry is deployed without further configuration.
176
167
 
177
168
  </Fragment>
178
169
  </Infrastructure>
@@ -155,16 +155,7 @@ resource "aws_vpc_security_group_egress_rule" "mcp_server_to_database" {
155
155
  }
156
156
  ```
157
157
 
158
- `appconfig_application_id`/`appconfig_application_arn` come from the shared <Link path="guides/runtime-config">runtime configuration</Link> AppConfig application declared once in your root module, not from the database module. Include the `database` namespace when instantiating it so the database module's runtime configuration entry is deployed:
159
-
160
- ```hcl title="packages/infra/src/main.tf"
161
- module "runtime_config_appconfig" {
162
- source = "../../common/terraform/src/core/runtime-config/appconfig"
163
-
164
- application_name = "my-app-runtime-config"
165
- namespaces = ["connection", "agentcore", "database"]
166
- }
167
- ```
158
+ `appconfig_application_id`/`appconfig_application_arn` come from the shared <Link path="guides/runtime-config">runtime configuration</Link> AppConfig application declared once in your root module, not from the database module. That application exposes the `database` namespace by default, so the database module's runtime configuration entry is deployed without further configuration.
168
159
 
169
160
  </Fragment>
170
161
  </Infrastructure>
@@ -161,16 +161,7 @@ resource "aws_vpc_security_group_egress_rule" "agent_to_database" {
161
161
  }
162
162
  ```
163
163
 
164
- `appconfig_application_id`/`appconfig_application_arn` come from the shared <Link path="guides/runtime-config">runtime configuration</Link> AppConfig application declared once in your root module, not from the database module. Include the `database` namespace when instantiating it so the database module's runtime configuration entry is deployed:
165
-
166
- ```hcl title="packages/infra/src/main.tf"
167
- module "runtime_config_appconfig" {
168
- source = "../../common/terraform/src/core/runtime-config/appconfig"
169
-
170
- application_name = "my-app-runtime-config"
171
- namespaces = ["connection", "agentcore", "database"]
172
- }
173
- ```
164
+ `appconfig_application_id`/`appconfig_application_arn` come from the shared <Link path="guides/runtime-config">runtime configuration</Link> AppConfig application declared once in your root module, not from the database module. That application exposes the `database` namespace by default, so the database module's runtime configuration entry is deployed without further configuration.
174
165
 
175
166
  </Fragment>
176
167
  </Infrastructure>
@@ -160,16 +160,7 @@ resource "aws_vpc_security_group_egress_rule" "mcp_server_to_database" {
160
160
  }
161
161
  ```
162
162
 
163
- `appconfig_application_id`/`appconfig_application_arn` come from the shared <Link path="guides/runtime-config">runtime configuration</Link> AppConfig application declared once in your root module, not from the database module. Include the `database` namespace when instantiating it so the database module's runtime configuration entry is deployed:
164
-
165
- ```hcl title="packages/infra/src/main.tf"
166
- module "runtime_config_appconfig" {
167
- source = "../../common/terraform/src/core/runtime-config/appconfig"
168
-
169
- application_name = "my-app-runtime-config"
170
- namespaces = ["connection", "agentcore", "database"]
171
- }
172
- ```
163
+ `appconfig_application_id`/`appconfig_application_arn` come from the shared <Link path="guides/runtime-config">runtime configuration</Link> AppConfig application declared once in your root module, not from the database module. That application exposes the `database` namespace by default, so the database module's runtime configuration entry is deployed without further configuration.
173
164
 
174
165
  </Fragment>
175
166
  </Infrastructure>
@@ -602,7 +602,7 @@ If you change the prefix for your stage names in your infrastructure project's `
602
602
  Additionally it's worth noting that the `load-runtime-config` target assumes a single stage of your application is deployed to the environment you have AWS credentials for. You will need to adjust the command if you deploy multiple stages to the same account and region.
603
603
  </Fragment>
604
604
  <Fragment slot="terraform">
605
- For Terraform projects, the `load-runtime-config` target copies the `runtime-config.json` file that was created after your most recent local `terraform apply`.
605
+ For Terraform projects, the `load-runtime-config` target copies the runtime config your most recent local `terraform apply` aggregated, from `dist/packages/common/terraform/runtime-config/connection.json`.
606
606
  </Fragment>
607
607
  </Infrastructure>
608
608
  :::
@@ -12,17 +12,19 @@ Runtime configuration is the mechanism used by Nx Plugin for AWS to pass deploy-
12
12
 
13
13
  Runtime configuration is organised into **namespaces**. Each namespace is a logical grouping of related configuration values. At deploy time, all namespaces are stored in **AWS AppConfig** as Configuration Profiles.
14
14
 
15
- Two built-in namespaces are used by generated constructs:
15
+ Four built-in namespaces are used by generated constructs:
16
16
 
17
17
  - **`connection`** — configuration that enables generated projects to connect to each other:
18
18
  - **API URLs** — registered automatically by API constructs
19
19
  - **Cognito settings** — registered automatically by the UserIdentity construct
20
20
  - **Agent runtime ARNs** — added by the connection generator when you connect a React website to an Agent
21
21
  - **`agentcore`** — AgentCore runtime ARNs for agents and MCP servers. Registered automatically by the agent/MCP constructs and used for server-side discovery (agent → agent via A2A, agent → MCP server).
22
+ - **`dynamodb`** — table names, registered automatically by DynamoDB table constructs and read by the generated table client.
23
+ - **`database`** — Aurora connection details, registered automatically by relational database constructs and read by the generated database client.
22
24
 
23
- The `connection` namespace is also deployed as a `runtime-config.json` file to your website's S3 bucket, enabling client-side discovery of backend resources. The `agentcore` namespace is server-side only (via AppConfig) so agent runtime ARNs are not exposed to the frontend unless you explicitly connect a website to an agent.
25
+ The `connection` namespace is also deployed as a `runtime-config.json` file to your website's S3 bucket, enabling client-side discovery of backend resources. The other namespaces are server-side only (via AppConfig), so values such as agent runtime ARNs and table names are not exposed to the frontend unless you explicitly connect a website to them.
24
26
 
25
- You can define as many additional namespaces as you like, providing a convenient alternative to environment variables for passing deploy-time values such as DynamoDB table names to your Lambda functions or other compute resources.
27
+ You can define as many additional namespaces as you like, providing a convenient alternative to environment variables for passing deploy-time values to your Lambda functions or other compute resources.
26
28
 
27
29
  ```d2
28
30
  direction: down
@@ -107,6 +109,17 @@ Terraform wires runtime configuration across three `core/runtime-config/*` modul
107
109
  }
108
110
  ```
109
111
 
112
+ The `namespaces` variable defaults to every built-in namespace, so generated modules work without configuring it. To add namespaces of your own, list them alongside the built-in ones:
113
+
114
+ ```hcl title="packages/infra/src/main.tf"
115
+ module "runtime_config_appconfig" {
116
+ source = "../../common/terraform/src/core/runtime-config/appconfig"
117
+
118
+ application_name = "my-app-runtime-config"
119
+ namespaces = ["connection", "agentcore", "database", "dynamodb", "tables"]
120
+ }
121
+ ```
122
+
110
123
  2. **`core/runtime-config/entry`** — one invocation per contribution. Generated API, agent and MCP modules call this internally to publish their URLs and ARNs. Call it directly to publish custom configuration.
111
124
 
112
125
  ```hcl title="packages/infra/src/main.tf"
@@ -89,16 +89,7 @@ resource "aws_vpc_security_group_egress_rule" "api_to_database" {
89
89
  }
90
90
  ```
91
91
 
92
- Deploy the API Lambda functions into **private subnets with egress**, not private isolated subnets. `appconfig_application_id`/`appconfig_application_arn` come from the shared <Link path="guides/runtime-config">runtime configuration</Link> AppConfig application declared once in your root module, not from the database module — passing them sets `RUNTIME_CONFIG_APP_ID` on the Lambda functions and grants them read access to the application. Include the `database` namespace when instantiating it so the database module's runtime configuration entry is deployed:
93
-
94
- ```hcl title="packages/infra/src/main.tf"
95
- module "runtime_config_appconfig" {
96
- source = "../../common/terraform/src/core/runtime-config/appconfig"
97
-
98
- application_name = "my-app-runtime-config"
99
- namespaces = ["connection", "agentcore", "database"]
100
- }
101
- ```
92
+ Deploy the API Lambda functions into **private subnets with egress**, not private isolated subnets. `appconfig_application_id`/`appconfig_application_arn` come from the shared <Link path="guides/runtime-config">runtime configuration</Link> AppConfig application declared once in your root module, not from the database module — passing them sets `RUNTIME_CONFIG_APP_ID` on the Lambda functions and grants them read access to the application. That application exposes the `database` namespace by default, so the database module's runtime configuration entry is deployed without further configuration.
102
93
 
103
94
  </Fragment>
104
95
  </Infrastructure>
@@ -47,7 +47,9 @@ This provisions a DynamoDB table with:
47
47
  - Customer-managed KMS encryption with automatic key rotation
48
48
  - Point-in-time recovery enabled
49
49
  - Deletion protection enabled
50
- - Table name registered in Runtime Config
50
+ - Table name registered in Runtime Config under the `dynamodb` namespace in AWS AppConfig
51
+
52
+ The `core/runtime-config/appconfig` module exposes the `dynamodb` namespace by default, so the table name is deployed without further configuration. If you pass `namespaces` to that module explicitly, keep `dynamodb` in the list — otherwise no configuration profile is created for it and the generated table client cannot resolve the table name.
51
53
  </Fragment>
52
54
  </Infrastructure>
53
55
 
@@ -52,16 +52,7 @@ module "my_database" {
52
52
 
53
53
  This provisions an Aurora cluster with RDS Proxy, admin credentials, create-db-user Lambda, runtime config registration, migration Lambda, and container registry resources.
54
54
 
55
- The database module registers its connection details under the `database` runtime configuration namespace. Include this namespace when instantiating the shared runtime configuration AppConfig application:
56
-
57
- ```hcl title="packages/infra/src/main.tf"
58
- module "runtime_config_appconfig" {
59
- source = "../../common/terraform/src/core/runtime-config/appconfig"
60
-
61
- application_name = "my-app-runtime-config"
62
- namespaces = ["connection", "agentcore", "database"]
63
- }
64
- ```
55
+ The database module registers its connection details under the `database` <Link path="guides/runtime-config">runtime configuration</Link> namespace, which the shared runtime configuration AppConfig application exposes by default.
65
56
 
66
57
  The generated infrastructure creates two database users:
67
58
  - **Admin user** - Created during cluster provisioning with credentials stored in AWS Secrets Manager
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aws/nx-plugin-mcp",
3
- "version": "1.0.0-rc.81",
3
+ "version": "1.0.0-rc.82",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/awslabs/nx-plugin-for-aws.git",