This is a simple reporter for kafka using the GraphiteReporter. It works with kafka 0.8.1.1 version.
Big thanks to Maxime Brugidou from Criteo who did the initial commit of the Ganglia version, available here https://github.com/criteo/kafka-ganglia
- Build the
kafka-graphite-1.0.0.jar
jar usingmvn package
. - Add
kafka-graphite-1.0.0.jar
andmetrics-graphite-2.2.0.jar
to thelibs/
directory of your kafka broker installation - Configure the broker (see the configuration section below)
- Restart the broker
Edit the server.properties
file of your installation, activate the reporter by setting:
kafka.metrics.reporters=com.criteo.kafka.KafkaGraphiteMetricsReporter[,kafka.metrics.KafkaCSVMetricsReporter[,....]]
kafka.graphite.metrics.reporter.enabled=true
Here is a list of default properties used:
kafka.graphite.metrics.host=localhost
kafka.graphite.metrics.port=8649
kafka.graphite.metrics.group=kafka
# This can be use to exclude some metrics from graphite
# since kafka has quite a lot of metrics, it is useful
# if you have many topics/partitions.
kafka.graphite.metrics.exclude.regex=<not set>
Simply build the jar and publish it to your maven internal repository (this package is not published to any public repositories unfortunately).