Recovering a job after admission
These four worker failure cases are proposed design tests. Follow a duplicate delivery, a stale claim, an orphaned artifact or an unknown provider charge to its own recovery condition.
Dispatch intent
Admission already committed a job and outbox row. A relay may publish the same job twice if it stops before marking the first send as complete.
Inspect the durable job
Look up the authoritative job ID before rendering. A completed job can be acknowledged immediately. New work requires an eligible claim.
Outgoing
Lease and generation
Each new claimant acquires a bounded lease and increments the generation. A slow worker can still compute after expiry, so the permission to publish is checked separately.
Outgoing
Immutable attempt object
Save the generation-specific output before publishing it. A process stop between storage and completion can leave a real object with no visible job pointer.
Outgoing
Guarded publication
Update the visible pointer only when the generation still owns the job. The test checks that a late worker cannot replace the current result.
Sweep orphan outputs
An unreferenced attempt object may be superseded during recovery. Inspect job pointers and remove orphaned objects later while preserving the visible winner.
Acknowledge completion
Inspect the published job ID and artifact pointer. Duplicate delivery may repeat work but only the winning completion should be visible.
Provider response missing
A paid provider may have accepted the work before timing out. Worker lease state says nothing about the provider’s charge.
Outgoing
Reuse provider identity
Where supported, query the operation or retry with the same provider identity. Record the resolved external outcome against the original job.
Park the unknown outcome
Without deduplication or lookup, mark the job for reconciliation and assign an owner before any replay. A timeout alone cannot establish absence of a charge.