fix: retry manifest push on GHCR rate limit, cap merge concurrency#449
Conversation
|
Warning Review limit reached
Next review available in: 51 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughThe publish workflow's merge job now caps concurrent matrix execution at 4 and wraps the docker buildx imagetools create manifest creation command in a retry loop, attempting up to 5 times with increasing backoff delays before failing the job. ChangesPublish Workflow Reliability
Estimated code review effort: 2 (Simple) | ~10 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
.github/workflows/publish.yml (1)
156-162: 🩺 Stability & Availability | 🔵 Trivial | ⚡ Quick winConsider disabling
fail-fastalongsidemax-parallel.With default
fail-fast: true, one target exhausting all 5 retries (e.g. due to sustained, not just burst, throttling) will cancel in-flight/queued merge jobs for other targets — undermining the reliability goal of this change. Consider addingfail-fast: falseso unrelated targets still complete independently.♻️ Suggested addition
strategy: # cap concurrent merge jobs so they don't collectively burst past GHCR's # manifest-push rate limit (all 12 targets pushing at once has triggered # 429 Too Many Requests on ghcr.io) max-parallel: 4 + fail-fast: false matrix: target: ${{ fromJson(needs.prepare.outputs.targets) }}🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In @.github/workflows/publish.yml around lines 156 - 162, The publish job’s matrix strategy currently limits concurrency with max-parallel but still uses the default fail-fast behavior, which can cancel unrelated target jobs if one target exhausts retries. Update the strategy in the workflow job that defines the target matrix to explicitly set fail-fast to false alongside max-parallel so each target’s merge job can complete independently even when another target fails.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In @.github/workflows/publish.yml:
- Around line 156-162: The publish job’s matrix strategy currently limits
concurrency with max-parallel but still uses the default fail-fast behavior,
which can cancel unrelated target jobs if one target exhausts retries. Update
the strategy in the workflow job that defines the target matrix to explicitly
set fail-fast to false alongside max-parallel so each target’s merge job can
complete independently even when another target fails.
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro Plus
Run ID: cca4238e-83d5-47fc-affe-abb513cf6c3b
📒 Files selected for processing (1)
.github/workflows/publish.yml
release/20260705's second attempt got past the build stage but every one of the 12 merge jobs failed identically: 429 Too Many Requests toomanyrequests: retry-after: ~10-25ms, allowed: 2000/minute All 12 merge jobs fire at once (one per target) and collectively burst past GHCR's short-window rate limit on manifest pushes. Caps merge job concurrency to 4 and retries `docker buildx imagetools create` up to 5 times with linear backoff, since the reported retry-after windows are on the order of milliseconds and a short wait is enough to clear the burst.
e5c9b8e to
3a0ef72
Compare
Summary
Fixes the failure in release/20260705's second run, after #448 fixed the earlier
bake --setparse error.All 36 build jobs succeeded this time, but all 12
mergejobs failed identically atdocker buildx imagetools create:All 12 merge jobs (one per target) fire simultaneously and collectively burst past GHCR's short-window rate limit on manifest pushes. The
retry-aftervalues GHCR reported were all under 25ms, meaning this is a brief burst limit, not sustained throttling — a short wait should clear it.Fix
strategy.max-parallel: 4on themergejob, so at most 4 targets push manifests concurrently instead of all 12 at oncedocker buildx imagetools createup to 5 times with linear backoff (5s, 10s, 15s, 20s) on failureValidation
actionlintandzizmorpass cleanTest plan
AI Disclosure
Per the project's AI-Assisted Contribution Policy:
max-parallelcap).actionlintandzizmorboth pass clean.Summary by CodeRabbit