Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[cdk pipelines] CDK - Issue with multiple Stacks within a Stage #9237

Closed
srethira opened this issue Jul 23, 2020 · 1 comment
Closed

[cdk pipelines] CDK - Issue with multiple Stacks within a Stage #9237

srethira opened this issue Jul 23, 2020 · 1 comment
Assignees
Labels
@aws-cdk/pipelines CDK Pipelines library guidance Question that needs advice or information.

Comments

@srethira
Copy link

❓ General Issue

Following this documentation https://aws.amazon.com/blogs/developer/cdk-pipelines-continuous-delivery-for-aws-cdk-applications/

The Question

Created a pipeline using CDK Pipelines. Added CDK Stage construct with two Stacks, which worked fine. When additional Stacks added to the Stage, ran into this issue. Any suggestions ?

Environment

  • CDK CLI Version: 1.51.0
  • Module Version: 1.51.0
  • Node.js Version: v14.5.0
  • OS: OSX Mojave
  • Language (Version): Python (3.7.3)

Other information

Do you wish to deploy these changes (y/n)? y
Pipeline: deploying...
[0%] start: Publishing XXXX-us-east-2
[100%] success: Published:XXXX-us-east-2
Pipeline: creating CloudFormation changeset...

❌ Pipeline failed: Error [ValidationError]: Template may not exceed 460800 bytes in size.
at Request.extractError (/usr/local/lib/node_modules/aws-cdk/node_modules/aws-sdk/lib/protocol/query.js:50:29)
at Request.callListeners (/usr/local/lib/node_modules/aws-cdk/node_modules/aws-sdk/lib/sequential_executor.js:106:20)
at Request.emit (/usr/local/lib/node_modules/aws-cdk/node_modules/aws-sdk/lib/sequential_executor.js:78:10)
at Request.emit (/usr/local/lib/node_modules/aws-cdk/node_modules/aws-sdk/lib/request.js:688:14)
at Request.transition (/usr/local/lib/node_modules/aws-cdk/node_modules/aws-sdk/lib/request.js:22:10)
at AcceptorStateMachine.runTo (/usr/local/lib/node_modules/aws-cdk/node_modules/aws-sdk/lib/state_machine.js:14:12)
at /usr/local/lib/node_modules/aws-cdk/node_modules/aws-sdk/lib/state_machine.js:26:10
at Request. (/usr/local/lib/node_modules/aws-cdk/node_modules/aws-sdk/lib/request.js:38:9)
at Request. (/usr/local/lib/node_modules/aws-cdk/node_modules/aws-sdk/lib/request.js:690:12)
at Request.callListeners (/usr/local/lib/node_modules/aws-cdk/node_modules/aws-sdk/lib/sequential_executor.js:116:18) {
code: 'ValidationError',
time: 2020-07-23T19:06:19.649Z,
requestId: '8092251f',
statusCode: 400,
retryable: false,
retryDelay: 590.3288129916684
}

Template may not exceed 460800 bytes in size.

@srethira srethira added guidance Question that needs advice or information. needs-triage This issue or PR still needs to be triaged. labels Jul 23, 2020
@github-actions github-actions bot added the @aws-cdk/pipelines CDK Pipelines library label Jul 23, 2020
njlynch added a commit that referenced this issue Jul 24, 2020
This change combines the two roles (and policies) per pipeline asset into a
single role + policy for all assets in a pipeline. In a small pipeline with only
3 assets, this reduced the overall template size by a third.

With a pipeline stack with 30 assets, this change reduces the template size from
363111 bytes to 190223 bytes.

Tested on a cross-account pipeline to verify permissions were retained.

fixes #9066
mitigates #9225
mitigates #9237
@ericzbeard ericzbeard removed the needs-triage This issue or PR still needs to be triaged. label Jul 24, 2020
mergify bot pushed a commit that referenced this issue Jul 28, 2020
…ies (#9243)

This change combines the two roles (and policies) per pipeline asset into a
single role + policy for all assets in a pipeline. In a small pipeline with only
3 assets, this reduced the overall template size by a third.

With a pipeline stack with 30 assets, this change reduces the template size from
363111 bytes to 190223 bytes.

Tested on a cross-account pipeline to verify permissions were retained.

fixes #9066
mitigates #9225
mitigates #9237


----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
@njlynch
Copy link
Contributor

njlynch commented Jul 28, 2020

This is mostly a duplicate of #9066, and a dupe of #9225. Closing this out to track any remainder in #9225.

@njlynch njlynch closed this as completed Jul 28, 2020
curtiseppel pushed a commit to curtiseppel/aws-cdk that referenced this issue Aug 11, 2020
…ies (aws#9243)

This change combines the two roles (and policies) per pipeline asset into a
single role + policy for all assets in a pipeline. In a small pipeline with only
3 assets, this reduced the overall template size by a third.

With a pipeline stack with 30 assets, this change reduces the template size from
363111 bytes to 190223 bytes.

Tested on a cross-account pipeline to verify permissions were retained.

fixes aws#9066
mitigates aws#9225
mitigates aws#9237


----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
@aws-cdk/pipelines CDK Pipelines library guidance Question that needs advice or information.
Projects
None yet
Development

No branches or pull requests

3 participants