Skip to content
Go client for AMQP 0.9.1
Branch: master
Clone or download
Type Name Latest commit message Commit time
Failed to load latest commit information.
_examples Fix publish channel redial Jul 6, 2017
spec Refactor to fix all but the Id -> ID lint errors Dec 5, 2016
.travis.yml Enables Go modules in TravisCI and adds Go 1.12.x Mar 12, 2019 Run golint/go vet in CI Dec 5, 2016
LICENSE (c) year Feb 24, 2019 Add go v1.11 to supported versions, soft drop go v1.9 (n-1 + tip proj… Nov 7, 2018
allocator.go tivial spelling fixes Jul 17, 2016
allocator_test.go Run golint and go vet in pre-commit Dec 5, 2016
auth.go Rotate certs with 10 year lifetime Jan 27, 2014
channel.go Revert "Channel exposes confirms in order to get sequential number of… Feb 25, 2019
confirms_test.go Format go source with simplify flag Nov 1, 2017
connection_test.go Make IsClosed() for Connection public. Closes #376 Dec 15, 2018
delivery.go Fix Ex[]hange typo in Delivery struct (#352) Nov 6, 2018
delivery_test.go Errors instead of panics on closed delivery chan Dec 1, 2014
doc.go Refactor to fix all but the Id -> ID lint errors Dec 5, 2016
fuzz.go the +build tag isn't a doc comment Oct 31, 2016 Use the BSD licensed amqp091 spec. Aug 10, 2013
integration_test.go Add go v1.11 to supported versions, soft drop go v1.9 (n-1 + tip proj… Nov 7, 2018
pre-commit Add go v1.11 to supported versions, soft drop go v1.9 (n-1 + tip proj… Nov 7, 2018
read.go Limit readLongstr to max(uint32). Fixes #261 May 13, 2017
reconnect_test.go Cleanup printfs found with go vet May 25, 2013
tls_test.go Interface compatibility with *tls.Conn Dec 5, 2016
uri.go Fixes pre-existing golint issues Mar 12, 2019
uri_test.go gofmt Sep 26, 2017
write.go Fix #363 where int is not treated as valid field Jan 6, 2019

Build Status GoDoc

Go RabbitMQ Client Library

This is an AMQP 0.9.1 client with RabbitMQ extensions in Go.

Project Maturity

This project has been used in production systems for many years. It is reasonably mature and feature complete, and as of November 2016 has a team of maintainers.

Future API changes are unlikely but possible. They will be discussed on Github issues along with any bugs or enhancements.

Supported Go Versions

This library supports two most recent Go release series, currently 1.10 and 1.11.

Supported RabbitMQ Versions

This project supports RabbitMQ versions starting with 2.0 but primarily tested against reasonably recent 3.x releases. Some features and behaviours may be server version-specific.


Provide a functional interface that closely represents the AMQP 0.9.1 model targeted to RabbitMQ as a server. This includes the minimum necessary to interact the semantics of the protocol.


Things not intended to be supported.

  • Auto reconnect and re-synchronization of client and server topologies.
    • Reconnection would require understanding the error paths when the topology cannot be declared on reconnect. This would require a new set of types and code paths that are best suited at the call-site of this package. AMQP has a dynamic topology that needs all peers to agree. If this doesn't happen, the behavior is undefined. Instead of producing a possible interface with undefined behavior, this package is designed to be simple for the caller to implement the necessary connection-time topology declaration so that reconnection is trivial and encapsulated in the caller's application code.
  • AMQP Protocol negotiation for forward or backward compatibility.
    • 0.9.1 is stable and widely deployed. Versions 0.10 and 1.0 are divergent specifications that change the semantics and wire format of the protocol. We will accept patches for other protocol support but have no plans for implementation ourselves.
  • Anything other than PLAIN and EXTERNAL authentication mechanisms.
    • Keeping the mechanisms interface modular makes it possible to extend outside of this package. If other mechanisms prove to be popular, then we would accept patches to include them in this package.


See the 'examples' subdirectory for simple producers and consumers executables. If you have a use-case in mind which isn't well-represented by the examples, please file an issue.


Use Godoc documentation for reference and usage.

RabbitMQ tutorials in Go are also available.


Pull requests are very much welcomed. Create your pull request on a non-master branch, make sure a test or example is included that covers your change and your commits represent coherent changes that include a reason for the change.

To run the integration tests, make sure you have RabbitMQ running on any host, export the environment variable AMQP_URL=amqp://host/ and run go test -tags integration. TravisCI will also run the integration tests.

Thanks to the community of contributors.

External packages


BSD 2 clause - see LICENSE for more details.

You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.