forked from aws/aws-cdk
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(cdk): changed retry mechanism for hotswapping AppSync.function (a…
…ws#32179) ### Reason for this change Fixing bug in hotswap for `AppSync.function` where `ConcurrentModificationException` error continues to appear when attempting hotswap on a large collection of resources. ### Description of changes Switches the retry mechanism for hotswapping AppSync.function from a simple retry where hotswap of AppSync.function is retried 5 times at 1 second intervals if a Concurrent Modification Exception occurs to an exponential back off retry, where the retry interval doubles with each failure. Exponential backoff will try 6 times (which through my testing should cover all reasonable cases) to resolve AppSync.function hotswap. ### Description of how you validated changes No integration or unit tests added. Passes all current unit tests. Tested locally on an Amplify project to ensure that cases that previously experienced `ConcurrentModificationException` errors no longer experienced them. ### Checklist - [x] My code adheres to the [CONTRIBUTING GUIDE](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) and [DESIGN GUIDELINES](https://github.com/aws/aws-cdk/blob/main/docs/DESIGN_GUIDELINES.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
1 parent
a73f84b
commit d14d784
Showing
2 changed files
with
164 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters