KafkaConsumerMetrics is now deprecated in Micrometer and the Kafka metrics() API should be used rather than JMX.