rabbitmq-tutorials/ruby
Michael Klishin 8f07ab696e Match Pika example in output
This is what test.py expects
2013-07-23 17:43:14 +04:00
..
emit_log_direct.rb Tutorial 4 ported to Bunny 2013-07-18 00:16:10 +04:00
emit_log_topic.rb Match output of the Pika version 2013-07-22 16:51:33 +04:00
emit_log.rb Make sure Bunny tutorials produce the same output as Pika 2013-07-22 11:04:03 +04:00
new_task.rb Make sure Bunny tutorials produce the same output as Pika 2013-07-22 11:04:03 +04:00
README.md README for the new Bunny-based version 2013-07-17 18:11:41 +04:00
receive_logs_direct.rb Be explicit about return codes 2013-07-23 17:42:55 +04:00
receive_logs_topic.rb Be explicit about return codes 2013-07-23 17:42:55 +04:00
receive_logs.rb Be explicit about return codes 2013-07-23 17:42:55 +04:00
receive.rb Be explicit about return codes 2013-07-23 17:42:55 +04:00
rpc_client.rb Make sure Bunny tutorials produce the same output as Pika 2013-07-22 11:04:03 +04:00
rpc_server.rb Match Pika example in output 2013-07-23 17:43:14 +04:00
send.rb Tutorial 1 code ported to Bunny 2013-07-17 18:21:48 +04:00
worker.rb Use :manual_ack as a more descriptive name 2013-07-22 15:30:34 +04:00

Ruby code for RabbitMQ tutorials

Here you can find Ruby code examples from RabbitMQ tutorials.

Requirements

To run this code you need Bunny 0.9+.

You can install it via RubyGems:

gem install bunny --version ">= 0.9.1"

Bunny supports Ruby 2.0, 1.9, JRuby, Rubinius 2.0, and Ruby 1.8.7.

Code

Tutorial one: "Hello World!":

ruby send.rb
ruby receive.rb

Tutorial two: Work Queues:

ruby new_task.rb
ruby worker.rb

Tutorial three: Publish/Subscribe

ruby receive_logs.rb
ruby emit_log.rb

Tutorial four: Routing

ruby receive_logs_direct.rb
ruby emit_log_direct.rb

Tutorial five: Topics

ruby receive_logs_topic.rb
ruby emit_log_topic.rb

Tutorial six: RPC

ruby rpc_server.rb
ruby rpc_client.rb

To learn more, visit Bunny documentation site.