I Know What RabbitMQ and Bunny are, How Do I Get Started?

What is Bunny Good For?

One can use Bunny to make Ruby applications interoperate with other
applications (both built in Ruby and not). Complexity and size may vary from
simple work queues to complex multi-stage data processing workflows that involve
many applications built with all kinds of technologies.

Specific examples:

Events collectors, metrics & analytics applications can aggregate events produced by various applications
(Web and not) in the company network.

A Web application may route messages to a Java app that works
with SMS delivery gateways.

MMO games can use flexible routing RabbitMQ provides to propagate event notifications to players and locations.

Price updates from public markets or other sources can be distributed between interested parties, from trading systems to points of sale in a specific geographic region.

Content aggregators may update full-text search and geospatial search indexes
by delegating actual indexing work to other applications over RabbitMQ.

Companies may provide streaming/push APIs to their customers, partners
or just general public.

Continuous integration systems can distribute builds between multiple machines with various hardware and software
configurations using advanced routing features of RabbitMQ.

An application that watches updates from a real-time stream (be it markets data
or Twitter stream) can propagate updates to interested parties, including
Web applications that display that information in the real time.

Supported Ruby Versions

Modern Bunny versions support

CRuby 2.2, 2.1, 2.0

Rubinius 2.0+

Bunny works sufficiently well on JRuby but there are known
JRuby bugs that cause high CPU burn. JRuby users should
use March Hare.

Bunny 1.7.x was the last version to support CRuby 1.9.3 and 1.8.7

Supported RabbitMQ Versions

Bunny 1.5.0 (including previews) and later versions only support RabbitMQ 3.3+.
Bunny 1.4.x and earlier supports RabbitMQ 2.x and 3.x.

Project Maturity

Bunny is a mature library (started in early 2009) with
a stable public API.

Before version 0.9, a lot of functionality was missing. Version
0.9 can be considered to be a "second birthday" for Bunny as it was
rewritten from scratch with over a dozen of preview releases over the
course of about a year.

We (the maintainers) made our best effort to keep the new version as
backwards compatible as possible but within reason.

Installation & Bundler Dependency

Most Recent Release

With Rubygems

To install Bunny with RubyGems:

gem install bunny

Bundler Dependency

To use Bunny in a project managed with Bundler:

gem"bunny", ">= 2.0.0"

Quick Start

Below is a small snippet that demonstrates how to publish
and synchronously consume ("pull API") messages with Bunny.

News & Announcements on Twitter

Reporting Issues

If you find a bug, poor default, missing feature or find any part of
the API inconvenient, please file an
issue on GitHub. When
filing an issue, please specify which Bunny and RabbitMQ versions you
are using, provide recent RabbitMQ log file contents if possible, and
try to explain what behavior you expected and why. Bonus points for
contributing failing test cases.

Running the Specs

The specs require RabbitMQ to be running locally with a specific set of vhosts
and users. RabbitMQ can be provisioned and started any that's convenient to you
as long as it has a suitable TLS keys configuration and management plugin enabled.
Make sure you have a recent version of RabbitMQ (> 3.5.3).

You can also start a clean RabbitMQ server
node on your machine specifically for the bunny specs.
To do so, run the following command
from the base directory of the gem: