fix(sl): add retries when creating indirection domain #935
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Problem
Creating the DNS indirection domain will fail when multiple site launches are performed in a single site launch form submission.
Solution
Breaking Changes
Bug Fixes:
@octokit/plugin-retry
) is used to automatically retry on retry-able errors. This includes the 409 error code returned by GitHub due to concurrent edits made to the indirection repository.Tests
Unable to test directly as this is a site launch change. However, the following code was used to simulate concurrent creation of files:
Without the retries, only one file will be created and the rest will have an error. Adding the retry plugin will allow all 10 files to be created successfully.
Deploy Notes
New dependencies:
@octokit/plugin-retry
: An octokit plugin to automatically retry on retry-able errors.