aws-cdk
aws-cdk copied to clipboard
feat(core): use literal for stack.partition (under feature flag)
closes #4092
When a Stack's region is a string literal, we can return a string literal from Stack.partition, resulting in easier to read generated templates.
All Submissions:
- [X] Have you followed the guidelines in our Contributing guide?
Adding new Unconventional Dependencies:
- [ ] This PR adds new unconventional dependencies following the process described here
New Features
- [ ] Have you added the new feature to an integration test?
- [ ] Did you use
yarn integto deploy the infrastructure and generate the snapshot (i.e.yarn integwithout--dry-run)?
- [ ] Did you use
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license
Thanks for your review @TheRealAmazonKendra I've updated the PR to include a feature flag, a minor update to the README, and confirmed the previously failing aws-iam integ tests are passing now.
Oh, I almost forgot, now that this is behind a feature flag, please update your PR to reflect that. We have specific formatting instructions in our contributing guide.
The most recent push includes the results of yarn integ --update-on-failed for each of the failing integration tests needed for my local run of ./build.sh to succeed. I'll review the results of the build fleet tomorrow and update as needed. I'm not sure why so many integ tests reported UNCHANGED on their snapshot comparisons, but I'm happy to investigate any that you think should be objecting. Is it possible they're using AWS.Region or a stack parameter for region?
The RegionInfo looks correct to me with 30 regions:
$ cat built-ins.generated.ts | grep FactName.PARTITION | awk '{print $3, $7;}'
"af-south-1", "aws"
"ap-east-1", "aws"
"ap-northeast-1", "aws"
"ap-northeast-2", "aws"
"ap-northeast-3", "aws"
"ap-south-1", "aws"
"ap-southeast-1", "aws"
"ap-southeast-2", "aws"
"ap-southeast-3", "aws"
"ca-central-1", "aws"
"cn-north-1", "aws-cn"
"cn-northwest-1", "aws-cn"
"eu-central-1", "aws"
"eu-north-1", "aws"
"eu-south-1", "aws"
"eu-south-2", "aws"
"eu-west-1", "aws"
"eu-west-2", "aws"
"eu-west-3", "aws"
"me-south-1", "aws"
"sa-east-1", "aws"
"us-east-1", "aws"
"us-east-2", "aws"
"us-gov-east-1", "aws-us-gov"
"us-gov-west-1", "aws-us-gov"
"us-iso-east-1", "aws-iso"
"us-iso-west-1", "aws-iso"
"us-isob-east-1", "aws-iso-b"
"us-west-1", "aws"
"us-west-2", "aws"
I'm confused about why the linter is failing. There are updates to READMEs in this change.
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).
AWS CodeBuild CI Report
- CodeBuild project: AutoBuildv2Project1C6BFA3F-wQm2hXv2jqQv
- Commit ID: 0f827985079c132bf73f4d1acc3811adee8b0af2
- Result: SUCCEEDED
- Build Logs (available for 30 days)
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).