CodeIssuesPull RequestsActionsSecurityInsights
✨ AI
More
Settings

feat(reliability): load-aware CI claim guard + niced steps + dead-man ping hook #5519

Merged⚡ AI-generatedXSccantynz wants to mergefeat/runner-load-guardmainopened 10d ago
ccantynzcommented 10d ago

Health-audit lane 1 (containment) + the paging half of lane 2

Structural fixes so 2026-08-22 cannot recur:

  1. Load-aware claim guardshouldDeferForLoad: the runner refuses to claim queued runs while 1-minute load exceeds WORKFLOW_LOAD_DEFER (default 2× core count). Queued rows just wait; the 2s tick re-checks. Whatever the concurrency setting, CI can no longer strangle the box it runs on. Windows loadavg is 0 → dev never defers. Hourly defer log, not per-tick.
  2. nice -n 10 on CI step subprocesses (POSIX only) — even an in-flight suite yields to the app's request handlers.
  3. External dead-man pings in heartbeat.yml — today the heartbeat detected all three outages (four red runs at exactly the right times) and paged nobody, because its only report channel lives on the monitored box. New steps ping HEALTHCHECK_PING_URL/fail on red and the bare URL on green; skipped with a note until the repo secret is set. Owner action: create the healthchecks.io check and add the secret — same account as the cutover dead-man.

Tests: 3 new guard tests (threshold, env override incl. garbage fallback, Windows-zero); abandonment pins and env-drift gate green; typecheck clean.

🤖 Generated with Claude Code

ccantynzAI Reviewcommented 10d ago

AI Triage

(no summary)

Priority: medium Risk area: mixed

Suggested labels: (no label suggestions) Suggested reviewers: (no reviewer suggestions)

Suggestions only — nothing has been applied. The PR author stays in control.

gluecron[bot]🤖 botAI Reviewcommented 10d ago

AI review unavailable

The platform's AI balance is exhausted, so AI generation is temporarily unavailable. Nothing was lost. You can queue this as a repair for the internal agent from the repository's Health page, or try again once the balance is restored. The PR is otherwise unchanged.

Cross-repo impact

See what breaks downstream if this PR merges.

Analyze →
⮌ Merged

This pull request was merged into main.

c comment · e edit title · m merge · a approve · r request changes · ? shortcuts