Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(core): allow overriding the stage name (aws#22223)
Currently the stage name is derived from the id of the stage and later becomes part of each stack name inside the stage: https://github.com/aws/aws-cdk/blob/c425e8ca1a3d296eb6a7fd7e005d07c1eadd16aa/packages/%40aws-cdk/core/lib/stage.ts#L139 https://github.com/aws/aws-cdk/blob/c425e8ca1a3d296eb6a7fd7e005d07c1eadd16aa/packages/%40aws-cdk/core/lib/stack.ts#L1139-L1143 Since the ids in a scope must be different, deploying the same stage in the same scope to multiple regions would require different ids and would then lead to different stack names in the end. To keep stack names uniform across regions, a stack already allows customising the stack name uncoupled from the id: https://github.com/aws/aws-cdk/blob/c425e8ca1a3d296eb6a7fd7e005d07c1eadd16aa/packages/%40aws-cdk/core/lib/stack.ts#L106-L111 This PR follows up on that concept and also allows customising the stage name. This would then allow to deploy the same stage in the same scope to multiple regions while keeping the resulting stack names the same across regions. ---- ### All Submissions: * [x] Have you followed the guidelines in our [Contributing guide?](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
- Loading branch information