Architecture · All ADRs
ADR 0008 — PostgreSQL outbox and job tables instead of a separate broker
Architecture decision record — status: Accepted.
Status: Accepted
Decision#
Domain events are written to an events outbox in the same transaction as the state change. Webhook deliveries, notification deliveries, approval expiry/escalation, execution resumption and retention are durable rows claimed with FOR UPDATE SKIP LOCKED by any number of worker replicas. Redis holds only ephemeral, rebuildable state (rate limits, limit windows, baselines, circuit breakers, revocation marks, caches).
Consequences#
- (+) Transactional enqueue, at-least-once delivery, full visibility and replay from SQL.
- (+) No additional infrastructure to operate.
- (−) Very high event volumes may need partitioning or a log-based transport; the dispatcher interface isolates that change.