1. Docker topology
- Docs
- SDKs, Recipes & Learning
- PostgreSQL Multi-Broker
- Overview
Three brokers. One database. Real work.
Launch a disposable PostgreSQL 19.0 cluster with three active bunqueue brokers and exercise queues, workers, events, retries, DLQ recovery, shared limits, and durable job graphs.
Architecture
Section titled “Architecture”Run two or more stateless brokers sharing one authoritative PostgreSQL 17-19 database
SKIP LOCKED, database-clock leases, and LISTEN/NOTIFY wakeups.Follow the example
Section titled “Follow the example”2. N queues and workers
3. Reliability controls
4. Durable flows
5. Production operations
6. Engineering report
One-command verification
Section titled “One-command verification”From the repository root with Docker running, run ./examples/postgres-multibroker/verify.sh — it creates an isolated Compose project, runs every scenario under a 60s deadline, and tears down all containers, volumes, networks, and local images on exit (including errors, timeouts, SIGINT, and SIGTERM).
Fleet invariants
Section titled “Fleet invariants”| Setting | Fleet rule |
|---|---|
| PostgreSQL URL & namespace | Same primary/HA endpoint; same namespace for shared queues (different to isolate envs) |
| Broker ID | Unique, stable per active process (never static --scale) |
| Connection pool & version | Budget brokers * (poolSize + 1) plus headroom; identical binary version across all brokers |
Functional correctness guide, not a throughput benchmark or PostgreSQL primary-failover certification. Next: build the Docker topology.