Engineering notes

A timeout can leave the outcome unknown

Retry identity and atomic state matter when successful work loses its acknowledgement.

A worker can finish its work before the caller hears back. If the response disappears, the caller sees a timeout while the result already exists. Stripe's network-error guidance describes this uncertainty directly: a broken connection does not establish whether the original operation succeeded.

Request Replay makes that sequence visible. The simulated store creates job_1, then its acknowledgement is lost. Redelivery brings the same event back with a new delivery ID. An unguarded worker creates another job; the guarded worker returns job_1.

The guard records the scoped event ID and resulting job together in one modelled transaction. That avoids a gap where the job exists but its completion record does not. Database transactions provide the underlying all-or-nothing concept.

There is a further boundary when work leaves the database. An email or payment cannot become atomic merely because a local ledger exists. An outbox can record delivery intent alongside local state, but its relay can still produce duplicates, so the recipient also needs a suitable duplicate-handling contract.

Request Replay models one serialized worker and an atomic store step. It runs entirely in the browser. The lesson concerns safe repetition under uncertainty; the simulation makes no production delivery guarantee.

Try the lost-acknowledgement scenario

All engineering notes