mimaison / prometheus-metrics-reporter

A Prometheus metrics reporter for Apache Kafka.
Apache License 2.0
0 stars 4 forks source link

How about micrometer? #7

Open grdryn opened 1 year ago

grdryn commented 1 year ago

I wonder if it would be useful to think about this as a Micrometer metrics reporter rather than solely a Prometheus one? My understanding is that users could then choose any of the systems that Micrometer supports, of which Prometheus is one.

https://micrometer.io/

I haven't used micrometer personally in any project yet, so I don't know what potential limitations or drawbacks there might be to such an approach.

mimaison commented 1 year ago

Thanks for the suggestion.

I'm not too familiar with Micrometer so correct me if I'm wrong. I see Micrometer as an API to define metrics. Kafka already uses its own libraries for defining metrics.

I think you mean a Kafka metrics reporter could grab the existing Kafka metrics and create the matching Micrometer metrics. Then we would need a way to specify the monitoring system to target and rely on Micrometer to do it. Unfortunately it looks like to setup the export mechanism you need some code so it's not completely free to support many systems.

At the moment, I've mainly built this to use it with Strimzi where Prometheus is the main target monitoring system and supporting other tools would have some additional cost.