Coder Social home page Coder Social logo

ruote-amqp's Introduction

ruote-amqp

ruote-amqp is a set of classes that let a ruote engine publish and/or receive messages over AMQP.

The most common use case is publishing workitems for processing by AMQP consumers and eventually receiving them back to resume the flow.

Another use case would be to listen on an AMQP queue for workflow launch requests.

Listening for arbitrary AMQP messages before resuming a flow (ambush/alert) is also possible.

usage

Ruote::Amqp::Participant

Publishing messages

  $dashboard.register(
    :toto,
    Ruote::Amqp::Participant,
    :exchange => [ 'direct', '' ],
    :routing_key => 'alpha')

  pdef = Ruote.define do
    toto
  end

  $dashboard.launch(pdef)

  # ...

Ruote::Amqp::Receiver

Receiving messages.

# TODO

Ruote::Amqp::AlertParticipant

Ambushing messages from a process definition.

# TODO

requirements

install

Please be sure to have read the requirements section above

gem install ruote-amqp

or via your Gemfile (thanks bundler).

tests / specs

To run the tests you need the following requirements met, or the testing environment will fail horribly (or simply get stuck without output).

RabbitMQ vhost

The tests use dedicated vhost on a running AMQP broker. To configure RabbitMQ you can run the following commands (the RabbitMQ server must be running):

$ rabbitmqctl add_vhost ruote-test
$ rabbitmqctl add_user ruote ruote
$ rabbitmqctl set_permissions -p ruote-test ruote '.*' '.*' '.*'

or by running:

$ rake prepare

If you need to change the AMQP configuration used by the tests, edit the +spec/spec_helper.rb+ file.

daemon-kit

Kenneth Kalmer, the original author of the ruote-amqp gem is also the author of DaemonKit a library/toolbox for building daemons.

It used to be the preferred way to wrap remote participants (as daemons) but lately Kenneth hasn't had much time for support. It's still full of excellent ideas.

license

MIT, see LICENSE.txt

ruote-amqp's People

Contributors

jmettraux avatar kennethkalmer avatar lbt avatar belucid avatar kubicek avatar chasmanrors avatar jpr5 avatar simianarmy avatar

Stargazers

Hartog C. de Mik avatar  avatar

Watchers

Hartog C. de Mik avatar James Cloos avatar

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.