Skip to content
Find file
Fetching contributors…
Cannot retrieve contributors at this time
74 lines (57 sloc) 1.96 KB

StatsD AMQP publisher backend


This is a pluggable backend for StatsD, which publishes stats to an AMQP topic exchange instead of graphite.


npm install statsd-amqp-backend


You have to give basic information about your AMQP server to use:

  backends: [ "statsd-amqp-backend" ]
, amqp: {
    host: 'localhost'
  , port: 5672
  , login: 'guest'
  , password: 'guest'
  , vhost: '/'
  , defaultExchange: ''
  , messageFormat: 'graphite' // can be 'graphite' or 'json'
  , ssl: {
      enabled : false
    , keyFile : '/path/to/key/file'
    , certFile : '/path/to/cert/file'
    , caFile : '/path/to/cacert/file'
    , rejectUnauthorized : false


When using messageFormat: 'json', at flush time the entire metrics payload will be sent to the defaultExchange using the routing key json_payload, with contentType application/json. Example:


When using messageFormat: 'graphite', at flush time each metric will be sent individually to the defaultExchange using the metric's key name as the routing key, with contentType text/graphite. Example: 0 1387255600 0 1387255600 4 1387255600 0 1387255600



If you want to contribute:

  1. Clone your fork
  2. Hack away
  3. If you are adding new functionality, document it in the README
  4. Push the branch up to GitHub
  5. Send a pull request
Jump to Line
Something went wrong with that request. Please try again.