How to enable consumer lag emitter on confluent kafka 7.5.2 docker container?

I am using the cp-enterprise-kafka:7.5.2 docker image. The docs said I can enable the consumer lag emitter from the broker.properties file, but I dont see the parameter anywhere in the file

it may be not included in the file as its set to false by default.

I would recommend to set it manually to true and see what happens.

best,
michael

Thank you for your suggestion. I have tried it, but it doesn’t seem to have any effect. Specifically, I added the “confluent.consumer.lag.emitter.enabled=true” and “confluent.consumer.lag.emitter.interval.ms=60000” to the end of the broker.properties file under /etc/kafka/kraft/ and restarted the container, and the change persists.

As you can see from my screenshot, there doesn’t seem to be any MBean related to consumer lag anywhere even after manually adding the parameter.

did you check the kafka root dir?

I have not. To be honest I am quite new to this. What do you suggest I should look for inside this directory?

something like
kafka.consumer.*

if my understanding is right you would like to monitor consumer lag?

best,
michael

Yes, I would like to monitor the consumer lag of various topics through kafka JMX. I was following the docs until I got stuck with trying to enable the consumer lag emitter.

need to check by myself
keep you posted

Hi @nhutan,
we have a open request to add it to jmx monitoring stack