The Comfortable Lie

A colleague argues that end-to-end exactly-once delivery is impossible across a network, yet your payments pipeline demonstrably charges each order once. What reconciles those two claims?

A

The broker assigns each message a monotonic sequence number and drops any repeat of one it has already handed out, which makes delivery itself exactly-once whatever the consumer does

B

Delivery stays at-least-once because an acknowledgement can always be lost, but idempotent processing collapses the duplicates so the observable effect happens once, which is effectively-once

C

Exactly-once delivery becomes achievable once the sender and the receiver run two-phase commit across the message and its side effect, so the pipeline genuinely delivers each message a single time

D

The pipeline is really at-most-once, and the charges appear complete only because loss is rare enough that nobody has reconciled the ledger against the payment provider