// the find
prometheus/jmx_exporter
A process for collecting metrics using JMX MBeans for Prometheus consumption
The official Prometheus JMX exporter, used to pull metrics from any JVM-based application via JMX MBeans and expose them in Prometheus format. Works either as a Java agent (attaches at startup) or as a standalone HTTP server that connects to a remote JMX endpoint. If you're running Kafka, Cassandra, Tomcat, or any other JVM service and want it in your Prometheus/Grafana stack, this is the standard tool.
The Java agent mode is genuinely convenient — no changes to the target application, just add a -javaagent flag and a YAML config file. The example configs for Kafka, Cassandra, Spark, ZooKeeper etc. are battle-tested and save hours of figuring out which MBeans matter. Rule-based metric renaming with regex capture groups gives you clean Prometheus metric names instead of the raw JMX hieroglyphics. Integration test suite runs against real Docker containers across multiple Java and Prometheus versions, so compatibility claims actually hold.
The YAML configuration for non-trivial setups is genuinely painful — regex rules for MBean name mapping require you to understand JMX object name structure before you can write a useful config, and the error messages when rules don't match are opaque. Standalone mode (connecting to a remote JMX port) exposes you to RMI's firewall-hostile behavior, which the docs underplay. There's no built-in way to reload config without restarting, so changing what you scrape on a live agent requires a JVM bounce. The exporter has no concept of metric cardinality protection — a misconfigured rule on a high-cardinality MBean will happily explode your Prometheus storage.