# Klag > Klag is an open-source Kafka consumer lag exporter built with Vert.x and Micrometer. It monitors consumer lag, lag velocity, hot partitions, time-based lag, data-loss risk, and consumer-group state, and exports to Prometheus, Datadog, or OTLP (OpenTelemetry). It also exposes an opt-in read-only MCP endpoint for AI agents. Source: https://klag.dev | Repository: https://github.com/themoah/klag ## Docs - [MCP Endpoint](https://klag.dev/ai/mcp/): Klag's opt-in, read-only MCP endpoint lets AI agents query consumer lag, find lagging groups, and run composite diagnose checks, served from an in-memory snapshot. - [Group Filtering](https://klag.dev/configuration/group-filtering/): Control which Kafka consumer groups Klag monitors using glob include and exclude patterns. - [Configuration Reference](https://klag.dev/configuration/reference/): Complete reference of every Klag environment variable across app, Kafka, metrics, hot partitions, time-based lag, MCP, OTLP, and logging. - [Kubernetes (Helm)](https://klag.dev/deployment/kubernetes/): Deploy Klag on Kubernetes with the official Helm chart, including SASL authentication and ServiceMonitor support. - [Native Image](https://klag.dev/deployment/native-image/): Run Klag as a GraalVM native binary for ~70-100 ms startup and ~44 MB RSS, ideal for fast scaling and low-footprint deployments. - [Strimzi](https://klag.dev/deployment/strimzi/): Klag works out of the box with Kafka clusters managed by the Strimzi operator on Kubernetes (KRaft). - [Build from Source](https://klag.dev/development/build/): Build and test Klag from source with Gradle and Java 21, including Helm chart tests and end-to-end suites with real Kafka. - [Contributing](https://klag.dev/development/contributing/): How to contribute to Klag. Fork, branch, run the test suites, and open a pull request. - [Comparison](https://klag.dev/getting-started/comparison/): How Klag compares to Burrow and KMinion for Kafka consumer lag monitoring. - [Installation](https://klag.dev/getting-started/installation/): Install Klag via the Helm chart, Docker, or a Docker environment file, including SASL authentication examples. - [Introduction](https://klag.dev/getting-started/introduction/): What Klag is, why consumer lag matters, and the key features of this Kafka lag exporter. - [Quick Start](https://klag.dev/getting-started/quick-start/): Run Klag with Docker in one command, or use the GraalVM native image for faster startup and lower memory. - [Klag: Kafka Consumer Lag Exporter](https://klag.dev/): Klag is an open-source Kafka consumer lag exporter built with Vert.x. Monitor lag, lag velocity, hot partitions, time-based lag, and group state with Prometheus, Datadog, or OTLP. - [Datadog](https://klag.dev/integrations/datadog/): Ship Klag metrics directly to Datadog using the Datadog Micrometer registry. - [Grafana Dashboard](https://klag.dev/integrations/grafana-dashboard/): Import Klag's pre-built Grafana dashboard for consumer lag, velocity, hot partitions, time-based lag, data-loss prevention, and JVM panels. - [OTLP & Grafana Cloud](https://klag.dev/integrations/otlp-grafana/): Export Klag metrics over OpenTelemetry (OTLP/HTTP) to Grafana Cloud, New Relic, or any OTLP-compatible backend. - [Prometheus](https://klag.dev/integrations/prometheus/): Scrape Klag metrics with Prometheus via the /metrics endpoint. - [ACL Permissions](https://klag.dev/kafka/acl-permissions/): The read-only Kafka ACLs Klag needs (DESCRIBE on cluster, topics, and groups) for self-managed Kafka and Confluent Cloud. - [Data Loss Prevention](https://klag.dev/metrics/data-loss-prevention/): Klag's retention-percent metric warns you before consumer lag exceeds Kafka retention and messages are permanently lost. - [Hot Partitions](https://klag.dev/metrics/hot-partitions/): Klag detects partitions with statistically abnormal throughput so you can find skewed load and bottlenecks within a topic. - [Lag Velocity](https://klag.dev/metrics/lag-velocity/): How Klag measures whether consumer lag is growing or shrinking over time, so you can catch problems before they escalate. - [Metrics Overview](https://klag.dev/metrics/overview/): The full catalog of metrics Klag exposes, covering consumer lag, offsets, group state, velocity, hot partitions, time-based lag, and data-loss prevention. - [Time-Based Lag](https://klag.dev/metrics/time-based-lag/): Klag estimates consumer lag in milliseconds and seconds-to-catch-up, beyond raw message counts, using Kafka log timestamps with a poll-history fallback. ## Full text - [Full documentation, concatenated](https://klag.dev/llms-full.txt)