fix(dynamodb-global): cannot deploy global tables due to unresolved resource dependencies#4748
Conversation
The DynamoDB global table construct was incorrectly declaring its dependencies. That resulted in resources in the coordinator stack depending on the global tables, which cannot work, as those are from different stacks. Changed the logic to declare dependencies between the stacks explicitly. Fixes aws#4676
|
Thanks so much for taking the time to contribute to the AWS CDK ❤️ We will shortly assign someone to review this pull request and help get it
|
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
eladb
left a comment
There was a problem hiding this comment.
Seems odd the test expectations were not updated.
Also, the PR description says that the dependencies were not correctly defined but it doesn’t explain what was the incorrect definition.
PR title for bugs should describe the bug and not the solution. The title is used in Changelog under “fixes” so it should speak in terms of the bug that was fixed and not the solution.
packages/@aws-cdk/aws-dynamodb-global/test/integ.dynamodb.global.expected.json
Show resolved
Hide resolved
Updated.
That's what I tried to do; the bug was an incorrect dependency declaration, but it manifested itself with being unable to use global DynamoDB tables with If you have a suggestion for a better title, I'm all ears. |
Usually the title of the bug (#4676) is a good title for the fix. Maybe rephrased and shortened a little: |
Changed. |
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
The DynamoDB global table construct was incorrectly declaring its dependencies,
having the coordinator stack depend on the resources in the table stacks,
instead of on the stacks themselves.
That resulted in resources in the coordinator stack depending on the global tables,
which cannot work, as those are from different stacks.
Changed the logic to declare dependencies between the stacks explicitly.
Fixes #4676
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license