Add backoff and jitter to deployment polling - #444
Merged
Conversation
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Review tier: Lite
Findings: 1
New issues introduced by this change (3)
| Severity | Finding |
|---|---|
src/internal/deployment.js — reporting_interval is parsed with Number(...) but not validated. If the input is non-numeric… |
|
README.md — The docs say the polling backoff is capped at 30 seconds, but the implementation caps only the… |
|
action.yml — This input description implies the overall polling interval is capped, but the code caps only the… |
What changed in this PR
This PR updates the deployment status polling loop to reduce load and avoid synchronized polling by adding exponential backoff and jitter to non-terminal, successful status checks, and updates the docs/built distribution to match.
Changes:
- Add ±20% jitter to polling delays and apply 1.5× exponential backoff (capped at 30s) after successful non-terminal status responses.
- Extend test coverage for backoff/jitter behavior and ensure error backoff remains separate from success backoff.
- Update
reporting_intervaldocumentation and rebuilddist/.
| File | Description |
|---|---|
| src/internal/deployment.js | Adds jitter helper and success-path reporting interval backoff logic. |
| src/__tests__/internal/deployment.test.js | Adds unit tests covering backoff, cap, jitter, and separation from error backoff. |
| README.md | Documents the updated polling semantics for reporting_interval. |
| dist/index.js | Rebuilt distribution bundle reflecting the polling changes. |
| action.yml | Updates the reporting_interval input description to reflect backoff/jitter behavior. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
tjyung
previously approved these changes
Sep 1, 2026
YiMysty
previously approved these changes
Sep 1, 2026
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
YiMysty
approved these changes
Sep 1, 2026
yoannchaudet
enabled auto-merge
September 1, 2026 21:27
YiMysty
approved these changes
Sep 1, 2026
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.


Summary
Testing
npm run format:checknpm run lint:checknpm run preparenpm test -- --runInBand