Lag metric to prometheus

What are my options for exporting the max lag of a topic into promethus?

I have reviewed the metrics API already and don’t see anything at the consumer group level.

Seems like there should be a jmx exporter endpoint that we could consumer from.

Thanks
Zach

Have you checked GitHub - lightbend/kafka-lag-exporter: Monitor Kafka Consumer Group Latency with Kafka Lag Exporter? It’s probably the easiest way to export the consumer lag from a Confluent Cloud deployment to Prometheus.

1 Like

Hi @zachariahyoung, per this doc at the moment this isn’t possible using the metrics API.

@mcascallares’s suggestion is a good alternative.

@mcascallares Yes we have reviewed this tool and have it working.

It just seems strange that I would have to use this tool.

Why can’t I pull this out of a jmx exporter or the Metrics API.