Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Configuration based RabbitMQ interface based on node-amqp
JavaScript
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
examples/adder
lib
test
README.md
package.json

README.md

pigeon

Configuration based RabbitMQ interface based on node-amqp

Installation

npm install pigeon-post

Synopsis

An example of connecting to a server, publishing an event and receiving it

Configuration file

publishers:
  -
    name: greeter
    options:
      type: fanout
    publishes:
      - greeting
subscribers
  -
    name: receptionist
    bindings:
      greeter:
        - greeting

Publisher

var Pigeon = require('pigeon').getInstance();

Pigeon
    .connect('config.yml')
    .publish('greeting', {value:'Hello World'})

Subscriber

var Pigeon = require('pigeon').getInstance();

Pigeon
    .connect('config.yml')
    .subscribe('receptionist', function(msg) {
        console.log(msg);
    });
Something went wrong with that request. Please try again.