You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: jvm-observ-lib/README.md
+46-7Lines changed: 46 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,15 +1,17 @@
1
-
# JVM observability lib
1
+
# JVM observability library
2
2
3
-
This lib can be used to generate dashboards, rows, panels, and alerts for JVM monitoring.
3
+
This library can be used to generate dashboards, rows, panels, and alerts for JVM monitoring.
4
4
5
5
Supports the following sources:
6
6
7
7
-`prometheus` (https://prometheus.github.io/client_java/instrumentation/jvm/#jvm-memory-metrics). This also works for jmx_exporter (javaagent mode) starting from 1.0.1 release.
-`otel_with_suffixes` OpenTelemetry JVM metrics following semantic conventions (https://opentelemetry.io/docs/specs/semconv/runtime/jvm-metrics/). Uses metric names like `jvm_memory_used_bytes`, `jvm_gc_duration_seconds`, etc. **Recommended for new deployments. Corresponds to semantic conventions v1.22.0 and later.**
9
+
-`otel_old` Legacy OpenTelemetry JVM metrics (https://github.com/open-telemetry/opentelemetry-java-contrib/blob/main/jmx-metrics/docs/target-systems/jvm.md). Uses `process_runtime_jvm_*` metric names. **Corresponds to semantic conventions v1.21.0 and earlier.**
10
+
-`otel_old_with_suffixes` Same as `otel_old` but with Prometheus suffixes added by the OTel collector (`add_metric_suffixes=true`). **Corresponds to semantic conventions v1.21.0 and earlier.**
11
+
-`java_micrometer` (springboot) (https://github.com/micrometer-metrics/micrometer/blob/main/micrometer-core/src/main/java/io/micrometer/core/instrument/binder/jvm/JvmMemoryMetrics.java). Can be seen when Micrometer to OTEL bridge is used.
12
+
-`java_micrometer_with_suffixes` (springboot) same, but with prometheus suffixes
11
13
-`prometheus_old` client_java instrumentation prior to 1.0.0 release: (https://github.com/prometheus/client_java/releases/tag/v1.0.0-alpha-4). This also works for jmx_exporter (javaagent mode) prior to 1.0.1 release.
12
-
-`jmx_exporter`. Works with jmx_exporter (both http and javaagent modes) and the folllowing snippet:
14
+
-`jmx_exporter`. Works with jmx_exporter (both http and javaagent modes) and the following snippet:
13
15
14
16
```yaml
15
17
lowercaseOutputName: true
@@ -22,6 +24,43 @@ rules:
22
24
- pattern : java.lang<type=(.*)>
23
25
```
24
26
27
+
## OpenTelemetry sources
28
+
29
+
The library supports multiple OpenTelemetry metric sources to accommodate different deployment scenarios:
30
+
31
+
### Recommended: `otel_with_suffixes`
32
+
Uses the latest OpenTelemetry JVM semantic conventions with metric names like:
33
+
- `jvm_memory_used_bytes{jvm_memory_type="heap", jvm_memory_pool_name="G1 Eden Space"}`
34
+
- `jvm_gc_duration_seconds_count{jvm_gc_name="G1 Young Generation", jvm_gc_action="end of minor GC"}`
0 commit comments