This repository has been archived by the owner on May 15, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 7
/
params.json
1 lines (1 loc) · 4.13 KB
/
params.json
1
{"google":"UA-1847891-10","body":"# statsdpy #\r\n\r\nSimple event based [statsd](http://github.com/etsy/statsd) implementation written in python using [eventlet](http://eventlet.net) with support for reporting to graphite using the pickle protocol.\r\n\r\n### Configuration ###\r\n\r\nstatsdpy sample config with default options:\r\n\r\n [main]\r\n #graphite host and port to connect too\r\n graphite_host = 127.0.0.1\r\n graphite_port = 2003\r\n graphite_pickle_port = 2004\r\n\r\n #address and port we should listen for udp packets on\r\n listen_addr = 127.0.0.1\r\n listen_port = 8125\r\n\r\n #If you track a large number of metrics you can use the pickle protocol\r\n pickle_protocol = no\r\n #max number of metrics to report in one go when using the pickle protocol\r\n pickle_batch_size = 300\r\n\r\n #enabling debug mode and running in the foreground (with -f) is a great way\r\n #to debug an app generating new metrics\r\n debug = no\r\n\r\n #How often to flush stats to graphite\r\n flush_interval = 10\r\n #calculate the XXth percentile\r\n percent_threshold = 90\r\n\r\n - Edit the config file appropriately for your environment\r\n - Start the service: `statsdpy-server start --conf=/path/to/your.conf`\r\n - Fire some udp counter, timer, or gauge events at statsdpy\r\n - Check syslog for any errors starting up or processing events\r\n - Profit!\r\n\r\n### Reporting using the pickle protocol ###\r\n\r\nIf you track a decent # of metrics you wanna switch to report to graphite using the [pickle protocol](http://graphite.readthedocs.org/en/latest/feeding-carbon.html#the-pickle-protocol). The pickle protocol is more efficient than the the plaintext protocol, and supports sending batches of metrics to carbon in one go. To enable it just set ``pickle_protocol`` to \"yes\" in your statsdpy.conf. Optionally, you can also adjust the max number of items per batch that is reported by adjusting the ``pickle_batch_size`` conf option.\r\n\r\n### Event Types ###\r\n\r\nAs with the original statsd implementation from [etsy](https://github.com/etsy/statsd) the following event types are supported:\r\n\r\n#### Counter ####\r\n\r\n sitelogins:1|c\r\n\r\nSimple counters. Add 1 to the \"sitelogins\" event bucket. It stays in memory until flushed to graphite as specified by the flush_interval.\r\n\r\n 500errors:7|c\r\n\r\nAnother counter, this time add \"7\" to the \"500errors\" event bucket.\r\n\r\n#### Timer ####\r\n\r\n pageload:320|ms\r\n\r\nThe \"pageload\" event took 320ms to complete this time. statsdpy computes the XXth percentile (as specified in the config), average (mean), lower and upper bounds for the configured flush interval.\r\n\r\n#### Gauge (simple arbitrary values)####\r\n\r\n snakes_on_this_mother_farking_plane:12|g\r\n\r\n### Combined Events ###\r\n\r\nThe etsy statsd implementation now supports combined events via seperation by newline. Statsdpy supports this method now as well:\r\n\r\n pageload:320|ms\\nfailedlogin:5|c\r\n\r\n### Sampling ###\r\n\r\n statusupdate:107|c|@0.1\r\n\r\nThis counter is being sent sampled every 1/10th of the time.\r\n\r\n 404error:3|c|@0.5\r\n\r\nThis counter is being sampled at a 50% rate.\r\n\r\n### Building .deb packages ###\r\n\r\nClone the repo and build the package with [stdeb](https://github.com/astraw/stdeb \"stdeb\") (sudo apt-get install stdeb):\r\n\r\n git clone git@github.com:pandemicsyn/statsdpy.git\r\n cd statsdpy\r\n python setup.py --command-packages=stdeb.command bdist_deb\r\n dpkg -i deb_dist/python-statsdpy_0.0.X-1_all.deb\r\n\r\n### Installation via setup.py ###\r\n\r\n- ``git clone git@github.com:pandemicsyn/statsdpy.git``\r\n- ``cd statsdpy``\r\n- ``python setup.py install``\r\n- Copy the sample config to /etc/statsdpy/statsdpy.conf\r\n- Edit /etc/statsdpy/statsdpy.conf as required for your environment\r\n- Start statsdpy ``/usr/bin/statsdpy-server --conf=/etc/statsdpy/statsdpy.conf start``\r\n- Optionally, a basic init script is provided as etc/statsdpy/statsdpy.init\r\n","note":"Don't delete this file! It's used internally to help with page regeneration.","name":"Statsdpy","tagline":"A python eventlet based statsd server"}