A city parking-fine service accepts payment callbacks that platforms may retry when the first response is lost. The handler currently charges the card on every invocation. What design change prevents double billing under at-least-once delivery?
Select an answer to reveal the explanation.
Short Explanation
Think of a payment like stamping a permit once: the second stamp should not invent a second fine. Retries are normal on flaky networks, so the write path must tolerate being called again with the same intent.
Full Explanation
At-least-once delivery means a successful charge can still be retried if the caller never saw the success. Non-idempotent writes then become business bugs such as double billing. Design the handler around a client-supplied or derived idempotency key so a repeated request returns the original outcome instead of applying the side effect again.