prometheus / jmx_exporter

A process for exposing JMX Beans via HTTP for Prometheus consumption
Apache License 2.0
2.97k stars 1.19k forks source link

How to monitor summary metrics using JMX exporter #809

Open anurag-appperfect opened 1 year ago

anurag-appperfect commented 1 year ago

For some metrics, it would be useful if we could see a few different percentiles (75, 95 and 99, for example) for metrics, which have constantly a lot of samples in short time periods. Can anybody help me to configure my java service to expose percentile metrics using jmx exporter ?

dhoard commented 1 year ago

The exporter only exposes metrics as exposed by JMX. If you want/need histograms, you would need to either create JMX MBeans that expose the percentiles or do it in in Prometheus (time series database.)

anurag-appperfect commented 1 year ago

Thank you for your answer, can you tell me a bit more about how we can achieve this in prometheus ?

dhoard commented 11 months ago

Typically you would use a Histogram to instrument your code.

HistogramTest is a good example of usage.

msistla96 commented 10 months ago

I'd like to also be able to define MBeans that captures Summary metrics. Are we able to define this in the JMX configuration? I didn't see any examples related to Summary or Histogram.