GithubHelp home page GithubHelp logo

chazsconi / beetle Goto Github PK

View Code? Open in Web Editor NEW

This project forked from xing/beetle

0.0 2.0 0.0 2.34 MB

High Availability AMQP Messaging With Redundant Queues

Home Page: http://xing.github.com/beetle/

License: MIT License

Ruby 99.56% Shell 0.44%

beetle's Introduction

Beetle

High Availability AMQP Messaging with Redundant Queues

About

Beetle grew out of a project to improve an existing ActiveMQ based messaging infrastructure. It offers the following features:

  • High Availability (by using multiple message broker instances)

  • Redundancy (by replicating queues)

  • Simple client API (by encapsulating the publishing/ deduplication logic)

More information can be found on the project website.

Usage

Configuration

# configure machines

Beetle.config do |config|
  config.servers = "broker1:5672, broker2:5672"
  config.redis_server = "redis1:6379"
end

# instantiate a beetle client

b = Beetle::Client.new

# configure exchanges, queues, bindings, messages and handlers

b.configure do |config|
  config.queue :test
  config.message :test
  config.handler(:test) { |message| puts message.data }
end

Publishing

b.publish :test, "I'm a test message"

Subscribing

b.listen_queues

Examples

Beetle ships with a number of example scripts.

The top level Rakefile comes with targets to start several RabbitMQ and redis instances locally. Make sure the corresponding binaries are in your search path. Open four new shell windows and execute the following commands:

rake rabbit:start1
rake rabbit:start2
rake redis:start1
rake redis:start2

Prerequisites

To set up a redundant messaging system you will need

  • at least 2 AMQP servers (we use RabbitMQ)

  • at least one Redis server (better are two in a master/slave setup, see REDIS_AUTO_FAILOVER.rdoc)

Gem Dependencies

At runtime, Beetle will use

For development, you’ll need

Authors

Stefan Kaes, Pascal Friederich, Ali Jelveh and Sebastian Roebke.

You can find out more about our work on our dev blog.

Copyright © 2010 XING AG

Released under the MIT license. For full details see MIT-LICENSE included in this distribution.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.