JaredKuolt / bunny forked from celldee/bunny

Another synchronous Ruby AMQP client

This URL has Read+Write access

JaredKuolt (author)
Tue Sep 29 15:39:28 -0700 2009
commit  028126e3b860e549038db5d21bd1cf45245b268d
tree    eaf62aa65388b4044a17e1f63eff39081c8f4b0b
parent  2869bb017fa55c763c48bd5ce175c3973135a201
bunny /
name age message
file .gitignore Mon Sep 07 04:15:53 -0700 2009 Reverse previous change to .gitignore [celldee]
file LICENSE Mon Apr 20 04:40:30 -0700 2009 Amend README and add LICENSE [celldee]
file README.rdoc Loading commit data...
file Rakefile Fri Jun 26 00:35:44 -0700 2009 Modifications to accommodate AMQP 0-9-1 [celldee]
file bunny.gemspec
directory examples/ Sun Sep 13 17:38:24 -0700 2009 Add Subscription classes and improve Queue#pop/... [celldee]
directory lib/
directory spec/ Mon Sep 21 01:25:04 -0700 2009 Change Client#returned_message to handle messag... [celldee]
README.rdoc

Bunny: A synchronous Ruby AMQP client

GitHub repo: github.com/celldee/bunny

Rubyforge: rubyforge.org/projects/bunny-amqp

Twitter: twitter.com/bunny_amqp

Google Group: groups.google.com/group/bunny-amqp

Blog: bunnyamqp.wordpress.com

DESCRIPTION:

Bunny is an AMQP (Advanced Message Queuing Protocol) client, written in Ruby, that is intended to allow you to interact with AMQP-compliant message brokers/servers such as RabbitMQ in a synchronous fashion.

It is based on a great deal of useful code from amqp by Aman Gupta and Carrot by Amos Elliston.

You can use Bunny to -

  • Create and delete exchanges
  • Create and delete queues
  • Publish and consume messages

Bunny is known to work with RabbitMQ versions 1.5.4, 1.5.5, 1.6.0 and version 0-8 of the AMQP specification.

INSTALL:

Rubyforge: gem install bunny

GitHub: gem install celldee-bunny

QUICK START:

   require 'bunny'

   b = Bunny.new(:logging => true)

   # start a communication session with the amqp server
   b.start

   # declare a queue
   q = b.queue('test1')

   # publish a message to the queue
   q.publish('Hello everybody!')

   # get message from the queue
   msg = q.pop[:payload]

   puts 'This is the message: ' + msg + "\n\n"

   # close the connection
   b.stop

EVEN QUICKER START

   require 'bunny'

   # Create a direct queue named 'my_testq'
   Bunny.run { |c| c.queue('my_testq') }

OTHER:

Please see the examples directory for additional usage information.