Skip to content

Conversation

@rix0rrr
Copy link
Contributor

@rix0rrr rix0rrr commented Jun 3, 2025

When CDK apps grow extremely large (think 10-100 stacks, 1000-10000 constructs), all metadata together begins to exceed 512MB, the maximum string size in NodeJS. People usually deal with this by disabling metadata, but they shouldn't have to.

In addition, even for manifests that don't exceed 512MB the extremely large size of the single JSON object slows down its writing and reading every time, even if the metadata doesn't need to be accessed.

An effective solution is to write the metadata of an artifact to a separate file. This PR introduces the ability for that into the Cloud Assembly schema, and updates the CLI to read from both sources if available.

Relates to aws/aws-cdk#34480.


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license

When CDK apps grow extremely large (think 10-100 stacks, 1000-10000
constructs), all metadata together begins to exceed 512MB, the maximum
string size in NodeJS. People usually deal with this by disabling
metadata, but they shouldn't have to.

In addition, even for manifests that don't exceed 512MB the extremely
large size of the single JSON object slows down its writing and reading
every time, even if the metadata doesn't need to be accessed.

An effective solution is to write the metadata of an artifact to a
separate file. This PR introduces the ability for that into the Cloud
Assembly schema, and updates the CLI to read from both sources if
available.

Relates to aws/aws-cdk#34480.
@github-actions github-actions bot added the p2 label Jun 3, 2025
@aws-cdk-automation aws-cdk-automation requested a review from a team June 3, 2025 13:21
Signed-off-by: github-actions <github-actions@github.com>
@codecov-commenter
Copy link

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 87.72%. Comparing base (2e92d71) to head (90310c8).

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #568   +/-   ##
=======================================
  Coverage   87.72%   87.72%           
=======================================
  Files          72       72           
  Lines       10087    10087           
  Branches     1330     1330           
=======================================
  Hits         8849     8849           
  Misses       1213     1213           
  Partials       25       25           
Flag Coverage Δ
suite.unit 87.72% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants