@@ -12,13 +12,18 @@ This exporter is intended to be run as a Java Agent, exposing a HTTP server
1212and serving metrics of the local JVM. It can be also run as a standalone
1313HTTP server and scrape remote JMX targets, but this has various
1414disadvantages, such as being harder to configure and being unable to expose
15- process metrics (e.g., memory and CPU usage).
15+ process metrics (e.g., memory and CPU usage). In particular all the
16+ ` jvm_* ` metrics like ` jvm_classes_loaded_total ` , ` jvm_threads_current ` ,
17+ ` jvm_threads_daemon ` and ` jvm_memory_bytes_used ` won't be availabe if
18+ using the standalone http server.
1619
17- ### ** NOTE **
20+ ### ** NOTES **
1821
19- ** Some JVM metric names have changed to conform with the [ OpenMetrics ] ( https://openmetrics.io/ ) specification. **
22+ ** - Metrics are no longer served on the root ( ` / ` ) path - use the ` /metrics ` path **
2023
21- ** Dashboards will need to be changed if referencing the changed JVM metrics.**
24+ ** - Some JVM metric names have changed to conform with the [ OpenMetrics] ( https://openmetrics.io/ ) specification.**
25+
26+ ** - Dashboards will need to be changed if referencing the changed JVM metrics.**
2227
2328https://prometheus.github.io/client_java/migration/simpleclient/#jvm-metrics
2429
@@ -27,12 +32,12 @@ https://prometheus.github.io/client_java/migration/simpleclient/#jvm-metrics
2732
2833** Running the exporter as a Java agent is strongly encouraged.**
2934
30- - [ jmx_prometheus_javaagent-1.0.0 .jar] ( https://repo1.maven.org/maven2/io/prometheus/jmx/jmx_prometheus_javaagent/1.0.0 /jmx_prometheus_javaagent-1.0.0 .jar )
35+ - [ jmx_prometheus_javaagent-1.0.1 .jar] ( https://repo1.maven.org/maven2/io/prometheus/jmx/jmx_prometheus_javaagent/1.0.1 /jmx_prometheus_javaagent-1.0.1 .jar )
3136
3237To run as a Java agent, download one of the JARs and run:
3338
3439```
35- java -javaagent:./jmx_prometheus_javaagent-1.0.0 .jar=12345:config.yaml -jar yourJar.jar
40+ java -javaagent:./jmx_prometheus_javaagent-1.0.1 .jar=12345:config.yaml -jar yourJar.jar
3641```
3742
3843Metrics will now be accessible at [ http://localhost:12345/metrics ] ( http://localhost:12345/metrics ) .
@@ -49,12 +54,12 @@ Example configurations can be found in the `example_configs/` directory.
4954
5055# # Running the Standalone HTTP Server
5156
52- - [jmx_prometheus_httpserver-1.0.0 .jar](https://repo1.maven.org/maven2/io/prometheus/jmx/jmx_prometheus_httpserver/1.0.0 /jmx_prometheus_httpserver-1.0.0 .jar)
57+ - [jmx_prometheus_httpserver-1.0.1 .jar](https://repo1.maven.org/maven2/io/prometheus/jmx/jmx_prometheus_httpserver/1.0.1 /jmx_prometheus_httpserver-1.0.1 .jar)
5358
5459To run the standalone HTTP server, download one of the JARs and run :
5560
5661` ` `
57- java -jar jmx_prometheus_httpserver-1.0.0 .jar 12345 config.yaml
62+ java -jar jmx_prometheus_httpserver-1.0.1 .jar 12345 config.yaml
5863` ` `
5964
6065Metrics will now be accessible at [http://localhost:12345/metrics](http://localhost:12345/metrics).
@@ -73,6 +78,12 @@ rules:
7378
7479As stated above, it is recommended to run JMX exporter as a Java agent and not as a standalone HTTP server.
7580
81+ **NOTES**
82+
83+ **- `jvm_*` metrics will not be available if running in standalone mode**
84+
85+ **- standard Java MBeans that provide JVM metrics will be available using the standard Java MBean ObjectNames**
86+
7687# # Building
7788
7889` ./mvnw clean package` to build.
0 commit comments