kminion icon indicating copy to clipboard operation
kminion copied to clipboard

Kminion consumer group info gathering incompatible with Kafka 4.1.0

Open schustersv opened this issue 3 months ago • 5 comments

Running Kminion 2.2.14, connecting to an Apache Kafka cluster that was recently upgraded to version 4.1.0. Since that upgrade, Kminion isn't able to retrieve consumer group info any more. For each attempt to read consumer offsets, the following lines are logged:

{"level":"warn","ts":"2025-09-24T06:32:18.035Z","logger":"main.minion_service","msg":"failed to decode offset commit value","topic":"__consumer_offsets","partition_id":21,"offset":2259385709,"error":"response did not contain enough data to be valid"} {"level":"warn","ts":"2025-09-24T06:32:18.035Z","logger":"main.minion_service","msg":"failed to decode offset record","error":"failed to decode offset commit value: response did not contain enough data to be valid"}

This leads to no consumer lag, offset commit and related metrics being reported any more, rendering Kminion unusable for monitoring consumer groups.

Kafka's kafka-consumer-groups cli tool can read the offsets fine on version 4.1.0, but either it has been updated to whatever changes have been made to consumer offsets topic or it's using an internal API instead of relying on reading consumer offsets directly.

Is this issue already known? Have other come across this?

schustersv avatar Sep 24 '25 06:09 schustersv

I haven't tested it with 4.1 yet, but they may have updated the format. You can use the different method to collect consumer group offsets (via the Kafka APi rather than reading from the topic) though.

weeco avatar Sep 24 '25 09:09 weeco

Thanks for the hint regarding the possibility to use Kafka's admin api. I had not yet recognized that this is possible and for some reasons the Kminion in question had offsetsTopic configured as source scrapeMode.

schustersv avatar Sep 24 '25 14:09 schustersv

Alright, so I tracked down the issue to an incompatibility in franz-go. This was fixed in the most recent release of franz-go, mainly kmsg v1.12.0.

I have created PR #317 to update franz-go in Kminion so it is fully compatible in offsetsTopic scrape mode with the benefits it brings.

schustersv avatar Oct 23 '25 09:10 schustersv

With the changes being merged, is it possible to release a new version of Kminion please?

schustersv avatar Dec 08 '25 09:12 schustersv

@schustersv Yes we should tag a new release. FWIW new docker images are built for every push against master: https://hub.docker.com/r/redpandadata/kminion/tags

weeco avatar Dec 08 '25 11:12 weeco