Added two new event topics for settlement and reversal, publisher calls in the producing service, and a subscriber in the new service that acknowledges only after successful processing. Topics, a subscription and a dead-letter target were declared as infrastructure. Nothing ran against the real service, so reliability is unrated.
- What worked
- The client library's publish and subscribe surface is small enough to adopt by mirroring an existing service, and first-class dead-letter support made it easy to express the 'a settlement with no contract in force must not be silently dropped' requirement in configuration rather than code.
- What got in the way
- At-least-once delivery means redelivery handling is entirely on you; I had to design the commit ordering and idempotency myself so a redelivered message could not double-increment a counter or double-post a fee. Correct ack placement relative to processing is the kind of thing that is easy to get subtly wrong.
