Skip to main content

A production-ready RabbitMQ client wrapper for Go

Automatic reconnection, declarative topology, publisher confirms, consumer middleware, and dead-letter queues — built on amqp091-go, with a fluent API and nothing left for you to reinvent.

go get github.com/KARTIKrocks/rabbitwrap

Auto-Reconnection

Exponential backoff for connections, publishers, and consumers, with a distinct callback when it permanently gives up

Declarative Topology

Exchanges, queues, and bindings restored after reconnects, and re-applied on a timer so a deleted binding cannot strand a consumer

Channel Recovery

A channel-level exception, not just a dropped connection, is caught and the channel re-established

Publisher Confirms

Correlated by delivery tag — a single confirmed publisher is safe to share across goroutines

Consumer Middleware

Logging, panic recovery, in-process retry, and broker-level backoff retry — or bring your own

Dead-Letter Queues

One call wires the dead-letter exchange, queue, and binding for a work queue

Concurrent Consumers

Configurable worker goroutines with graceful, bounded shutdown

Thread Safe

Connections and publishers are safe for concurrent use

Why rabbitwrap?

A raw amqp091-go connection gets you a channel. Everything past that — the parts that turn "I can publish a message" into "I can run this in production" — is what rabbitwrap provides. It is not a replacement for the AMQP protocol library; it is built on top of one.

CapabilityrabbitwrapRaw amqp091-go
Reconnection with exponential backoffIncludedYou build it
Topology that survives reconnects and deletionsIncludedYou build it
Channel-level exception recoveryIncludedYou build it
Dead-letter queue wiringIncludedYou build it
Broker-level backoff retryIncludedYou build it
Consumer middleware chainIncludedYou build it
Graceful, bounded shutdownIncludedYou build it
Health checks via IsHealthy()IncludedYou build it