Skip to content

ci: cancel in-flight download-index runs when a new one starts#313

Merged
igorpecovnik merged 1 commit into
mainfrom
cancel-running-download-index
May 10, 2026
Merged

ci: cancel in-flight download-index runs when a new one starts#313
igorpecovnik merged 1 commit into
mainfrom
cancel-running-download-index

Conversation

@igorpecovnik
Copy link
Copy Markdown
Member

Summary

One-line concurrency tweak on `data-update-download-index.yml`:

```diff
concurrency:
group: ${{ github.workflow }}

  • cancel-in-progress: false
  • cancel-in-progress: true
    ```

Why

A fresh trigger (SDK build dispatch, release publish, manual retry) currently has to wait behind any older run still mid-rsync against `fi.mirror.armbian.de`. Two consequences:

  • The mirror connection from the stale run stays open for its full duration — wasted slot.
  • If a slow run eventually finishes after a newer one was queued, yesterday's index can land over today's.

Cancelling the in-flight run on every new trigger preempts both: the freshest data wins, and the rsync slot frees immediately.

The commit step at the bottom of the job writes `armbian-images.json` + `all-torrents.zip` atomically to the `data` branch — a cancelled run leaves nothing half-written.

Test plan

  • Trigger `Data: Generate Armbian download index` manually, then trigger it again before the first finishes; confirm the older run shows "Cancelled" in the run list.
  • Confirm the newer run completes and lands a fresh `armbian-images.json` on `data`.

Flip concurrency.cancel-in-progress from false to true so a fresh
trigger (SDK build dispatch, release publish, manual retry) preempts
any older run still mid-rsync. Stale runs hold rsync connections to
fi.mirror.armbian.de open for the full duration; cancelling them
immediately frees the slot and avoids landing yesterday's index over
today's after a slow run finally finishes.

The job's own commit step is idempotent (writes armbian-images.json
to the data branch), so a cancelled run leaves nothing half-written —
the next run regenerates from the source of truth anyway.
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 10, 2026

Warning

Rate limit exceeded

@igorpecovnik has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 19 minutes and 28 seconds before requesting another review.

You’ve run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 451e92ee-1e4e-4334-802e-50747c6a1def

📥 Commits

Reviewing files that changed from the base of the PR and between 1e0c028 and 5c7607b.

📒 Files selected for processing (1)
  • .github/workflows/data-update-download-index.yml
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch cancel-running-download-index

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions github-actions Bot added the 05 Milestone: Second quarter release label May 10, 2026
@igorpecovnik igorpecovnik merged commit c07edee into main May 10, 2026
5 checks passed
@igorpecovnik igorpecovnik deleted the cancel-running-download-index branch May 10, 2026 18:31
@github-actions github-actions Bot added size/small PR with less then 50 lines GitHub Actions GitHub Actions code Needs review Seeking for review and removed size/small PR with less then 50 lines labels May 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

05 Milestone: Second quarter release GitHub Actions GitHub Actions code Needs review Seeking for review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant