finds.dev← search

// the find

seglo/kafka-lag-exporter

★ 667 · Scala · Apache-2.0 · updated Feb 2024

Monitor Kafka Consumer Group Latency with Kafka Lag Exporter

Kafka Lag Exporter scrapes consumer group offsets from Kafka brokers and exposes them as Prometheus metrics, including an estimated lag-in-seconds metric calculated via linear interpolation between offset snapshots. It's built on Akka Typed and Scala, targets Kubernetes/Strimzi setups primarily, but runs standalone too. If you run Kafka and care about whether your consumers are keeping up, this fills a gap the official Kafka metrics don't cover well.

The lag-in-seconds metric is the real reason to use this — raw offset lag is useless without knowing message production rate, and the interpolation approach is sound for most workloads. Strimzi auto-discovery is genuinely useful: drop it in and it finds your clusters without static config. The multi-sink support (Prometheus, InfluxDB, Graphite) means you're not locked into one monitoring stack. The Helm chart is well-structured with proper RBAC templates, whitelist/blacklist regex per cluster, and optional Redis persistence for the lookup table.

Last commit was February 2024 and the repo has been effectively abandoned since Lightbend handed it off — open issues pile up with no maintainer response. The Akka dependency is a liability: Lightbend relicensed Akka as BSL in 2022, meaning any version past 2.6 requires a commercial license, and this project is stuck on whatever Akka version it last pinned. The lag-in-seconds estimate breaks down with highly variable throughput or sparse partitions — it's linear interpolation between two poll points, so spiky workloads will produce garbage estimates. The in-memory lookup table defaults to 60 data points per partition, which at the default 30-second poll interval gives you only 30 minutes of history before old points are evicted, making the time-lag calculation unreliable for low-traffic topics.

View on GitHub →

// want more like this?

We dig through GitHub every week and send a few repos picked for what you actually care about — each with an honest take like this one.

Get finds in your inbox → Search again →