Graphite emitter/sink for Presto. It allows to send Presto co-ordinator, worker, query metrics to Graphite in plaintext format.
- Python 2.7 or above
- Below packages needs to be installed,
- requests
- graphitesend
- Graphite server
Above python packages can be installed using below commands,
sudo pip -q install requests==2.8.1
sudo pip -q install graphitesend
Graphite installation instructions are available at Graphite documentation
Presto graphite emitter is a python script which collects Presto metrics and emits them to Graphite server in plaintext format. Presto metrics are exposed using JMX MBeans. Available metrics are collected, transformed into required format and sent to graphite server.
After installation of required packages, presto metric emitter needs to 5 parameters,
- PrestoDB co-ordinator IP Address
- PrestoDB co-ordinator Port
- Graphite server IP Address
- Graphite server Port
- Interval
Interval (in seconds) will be used to periodically collect metrics. Below command can be used,
Syntax:
nohup prestodb-graphite-emitter.py [Prestodb_CoOrd_IP] [Prestodb_CoOrd_Port] [Graphite_IP] [Graphite_Port] [Interval in sec] > nohup.out &
Example:
nohup prestodb-graphite-emitter.py 127.0.0.1 8285 127.0.0.1 2003 10 > nohup.out &
Emitted metrics will be in prefixed with nodenames to differentiate different worker nodes in cluster. Currently all metrics available via Presto JMX are supported and are configurable through prestodb-graphite-emitter.py script.
Few important included metrics classes are,
query_manager
query_execution
node_scheduler
task_executor
task_manager
cluster_memory_manager
Seperate metric configuration file and auto dependencies installation will be available in next version of this emitter. Emitted metrics can be viewed using Graphite or Grafana dashboards.