简体   繁体   中英

GenericJMXConfMBean: No MBean matched the ObjectName kafka.network:type=RequestMetrics,name=RequestsPerSec,request=Produce

I am working on a project where I am trying to collect the apache Kakfa request rate metric using the mbean metric 'kafka.network:type=RequestMetrics,name=RequestsPerSec,request={Produce|FetchConsumer|FetchFollower}' defined in the apache documentation. I am using collectd plugin to collect these metrics. But I am getting the error No MBean matched with the object name. For other mbean metrics, it is working correctly.

I tried pulling the metrics using jmx tool as well and it failed for this metric. kafka-run-class kafka.tools.JmxTool --jmx-url service:jmx:rmi:///jndi/rmi://localhost:9090/jmxrmi --object-name kafka.network:type=RequestMetrics,name=RequestsPerSec,request=Produce

I want the request rate metric for all the 3 producer, fetch consumer, fetch follower. Should I be using some other metric? The kafka version I am using is 2.1

The metric has been added with an API version tag. See the description below:

KIP-272 added API version tag to the metric kafka.network:type=RequestMetrics,name=RequestsPerSec,request={Produce|FetchConsumer|FetchFollower|...}. This metric now becomes kafka.network:type=RequestMetrics,name=RequestsPerSec,request={Produce|FetchConsumer|FetchFollower|...},version={0|1|2|3|...}. This will impact JMX monitoring tools that do not automatically aggregate. To get the total count for a specific request type, the tool needs to be updated to aggregate across different versions.

Retry with the version tag to see if it works.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM