Amqp queue information to statsd
Example
Configuration
In the config.json file you will find all the application configuration
{
"collectInterval": 30000, // collect interval time in ms
"amqp": {
"username": "AMQP_USERNAME",
"password": "AMQP_PASSWORD",
"host": "AMQP_HOSTNAME:15672", // might be something like heroku.srs.rabbitmq.com/rabbitmq/foobar
"protocol": "HTTP_OR_HTTPS"
},
"statsd": {
"host": "STATSD_HOSTNAME",
"port": "8125", // port of your statsd
"prefix": "STATSD_PREFIX" // prefix for your stats ex rabbit.prod / rabbit.dev
},
"logPath": "rabbit.log"
}
Install
Clone the remository
$ git clone https://github.com/lahaxearnaud/rabbitmq-statsd
Docker images: 47MB
```
$ make build
- Start the container
```sh
$ make up
docker rm rabbitmq-collector-container | true
docker run --name rabbitmq-collector-container -v /home/pirate/domotique-rabbitmq-statsd:/var/app -d rabbitmq-collector forever /var/app/app.js
4645aa2efcc4946924be0faa8237e4163ba5a2771ef9b72d488ff4e22e79e610
```
$ make tail
- Stop the container
```sh
$ make down
docker kill rabbitmq-collector-container | true
```
$ make rm
## Run without docker with forever
```sh
$ forver start app.js
$ npm run app
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue
LAHAXE Arnaud
Copyright © 2016 LAHAXE Arnaud
Licensed under the MIT license.
What better way to relax, after spending hours coding, than a good cocktail on the terrace?