prometheus / jmx_exporter

A process for exposing JMX Beans via HTTP for Prometheus consumption

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

difference between metrics in jmx exporter

acharbha opened this issue · comments

my /opt/activemq/conf/jmxexporter.yml is configured to enable all metrics -
echo 'rules:

  • pattern: ".*"' > /opt/activemq/conf/jmxexporter.yml

I would like to understand the difference between these 2 metrics, are they same if so why there's a difference and if they are different why do we say same name java heap memory ?
Can someone please help me understand this ?

# HELP jvm_memory_bytes_used Used bytes of a given JVM memory area.
# TYPE jvm_memory_bytes_used gauge
jvm_memory_bytes_used{area="heap",} 5.694892E7

# HELP java_lang_Memory_HeapMemoryUsage_used java.lang.management.MemoryUsage java.lang:name=null,type=Memory,attribute=used
# TYPE java_lang_Memory_HeapMemoryUsage_used untyped
java_lang_Memory_HeapMemoryUsage_used 6.21918E7

The metrics use the same Java MBean java.lang:type=MemoryPool but collect the value at different times. If the heap usage changes between calls to the MBean, you will have different values.