Capabilities

Messaging & Reliability

Outbox, inbox, and eight broker transports behind one abstraction — exactly-once effects over at-least-once delivery.

The moment an event must leave your service, two classic bugs are waiting: the dual write (database saved, message never sent — or the reverse) and the duplicate delivery (one event, two side effects). Relay ships both halves of the answer.

What ships: the outbox (integration events staged in the same PostgreSQL transaction as your state change, relayed to the broker by a background processor), the inbox (idempotent, exactly-once processing of at-least-once delivery), end-to-end reliable flow with dead-letter queues, retention and backlog maintenance, error policies (kill-switch, rate, circuit, backpressure), claim-check for large payloads, and partitioning.

Transports are pluggable behind IMessageBroker / IMessageConsumer: RabbitMQ, Kafka, Azure Service Bus, Amazon SQS, NATS, Pulsar, ActiveMQ (NMS) and in-memory for tests. Swapping brokers is configuration, not a rewrite.

The stories behind it: The Payment That Published But Never Happened, The Email That Sent Itself Five Times, and The Partner Who Spoke a Different Language.

Learn by building

The tutorials for this area, in order — each with a runnable sample.