An eventmachine-based statsd server written in ruby with a modular backend system. The motivation behind creating Yet Another Statsd Server was that while the existing ones allowed you to specify different backends to flush data to, it was always aggregated the same way and flushed on the same interval. This library incurs the overhead of multiple copies of your statistics with the tradeoff that you can have backend-specific flush intervals and alternate aggregations of your data.
Installation
$ gem install multi-statsd
Configuration
Configuration is done via a YAML file which is specified on the command line. Example config file:
# Host and port to listen on
host: 127.0.0.1
port: 8125
verbosity: 1 # 0-4, 0 being the most verbose
logfile: /var/log/multi-statsd.log
pidfile: /var/run/multi-statsd.pid
daemonize: true
backends:
stdout_every_5:
backend: Stdout
flush_interval: 5
hottie:
backend: Hottie
host: 127.0.0.1
port: 6379
flush_interval: 1
seconds_to_retain: 60
Usage
Usage is straight forward:
$ multi-statsd -c /path/to/config
Todo
- Create graphite backend
- Create relay backend
Contributing
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request