← ClaudeAtlas

durable-background-jobslisted

Lease-oriented discipline for durable background jobs. Use when designing, implementing, auditing, or diagnosing work that must survive request or worker failure: queues/workers and retries; visibility timeouts, heartbeats, stuck or poison jobs, and crash recovery; recurring jobs or scheduled billing; long backfills, checkpointing, cancellation, or drain. Route event/command delivery to reliable-messaging and multi-process business orchestration elsewhere.
Dankosik/agent-skills · ★ 0 · API & Backend · score 70
Install: claude install-skill Dankosik/agent-skills
# Durable Background Jobs Use the **lease** as the lens for every job: `identity -> durable acceptance -> claim/lease -> execute -> durable effect -> complete -> retry/recover -> prove` A lease is expiring permission to attempt work, not proof that no other attempt exists. Design for overlapping attempts. Promise one durable business effect through idempotency, a unique ledger or conditional write, or reconciliation; never promise exactly-once execution. ## Choose the branch Run only the branch and concerns the request needs. Record missing evidence as a gap instead of broadening the task. - **Audit or diagnose:** trace the real producer-to-effect path and every caller of the shared transition code. Find the first illegal or ambiguous commit boundary, report the root cause, and propose the smallest fix plus a runnable proof. Keep code and production unchanged. - **Design or plan:** define the in-scope contract and decisions. Supply SQL, pseudocode, matrices, and test cases only to the fidelity requested; label them proposed. - **Build or fix:** patch the shared root cause locally and run the smallest proof that fails on the old behavior and passes on the new behavior. - **Operate:** production enqueue, retry/requeue, schedule change, cancellation, purge, drain, backfill, or data repair requires explicit authorization for the exact action and targets. Preflight, execute only that action, then verify with fresh readback. Hand event and command delivery to `reliable-messa