New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Micrometer Meters Missing with Boot 2.3 #914
Comments
Resolves spring-cloud#914 Boot no longer uses the deprecated JMX MBean scraping provided by Micrometer. Add configuration to add Micrometer Meters when Micrometer and spring-kafka 2.5.x are on the class path.
Resolves spring-cloud#914 Boot no longer uses the deprecated JMX MBean scraping provided by Micrometer. Add configuration to add Micrometer Meters when Micrometer and spring-kafka 2.5.x are on the class path. Micrometer for Streams - work around until SK 2.5.3
We are also seeing this issue. The fix provided was for metrics to appear when spring-kafka is on the classpath. Our classpath does not have spring-kafka. It has:
We also set spring.jmx.enabled=true Any suggestions as to getting the metrics back? |
Boot only does auto configuration when spring-kafka is present. |
Thanks, @garyrussell. We ended up manually binding our KafkaStreams to the Micrometer registry. private void bind(
org.apache.kafka.streams.KafkaStreams kafkaStreams,
io.micrometer.core.instrument.MeterRegistry meterRegistry
) {
new KafkaStreamsMetrics(
kafkaStreams,
defaultTagSet()
).bindTo(
meterRegistry
);
} |
I encountered this too, and I tried adding |
@dlipofsky This is a closed issue. Could you please create a new issue and link to this one? Please provide more context as to what is not working, sample code, configuration, etc. Thanks! |
@sobychacko since it is closed, is there a solution? There's no milestone, and I was hoping someone on this thread would tell me what the actual fix is. |
It was fixed before (see the commit above). I am not sure if the issues you are running into are the same or if there were some regressions that happened with the recent releases. That's why I suggested creating a new issue and then we can re-evaluate things. Looks like we missed adding a milestone marker on this issue. This change was originally part of the |
Boot 2.3 switched from JMX scraping to native Micrometer meters in 2.3.
This is facilitated by adding a listener to the producer/consumer factory.
Since the binder creates its own factories; these meters are now missing.
https://stackoverflow.com/questions/62292889/kafka-consumer-metrics-gone-upon-upgrade-from-spring-boot-2-2-2-to-2-3-0
The text was updated successfully, but these errors were encountered: