Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion instrumentation/jmx-metrics/library/jvm.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Here is the list of metrics based on MBeans exposed by the JVM and that are defi
Those metrics are defined in the [JVM runtime metrics semantic conventions](https://opentelemetry.io/docs/specs/semconv/runtime/jvm-metrics/).

| Metric Name | semconv maturity | Type | Attributes | Description |
|---------------------------------------------------------------------------------------------------------------------------------------|:-----------------|---------------|---------------------------------------|----------------------------------------------------|
| ------------------------------------------------------------------------------------------------------------------------------------- | :--------------- | ------------- | ------------------------------------- | -------------------------------------------------- |
| [jvm.memory.used](https://opentelemetry.io/docs/specs/semconv/runtime/jvm-metrics/#metric-jvmmemoryused) | stable | UpDownCounter | jvm.memory.pool.name, jvm.memory.type | Used memory |
| [jvm.memory.committed](https://opentelemetry.io/docs/specs/semconv/runtime/jvm-metrics/#metric-jvmmemorycommitted) | stable | UpDownCounter | jvm.memory.pool.name, jvm.memory.type | Committed memory |
| [jvm.memory.limit](https://opentelemetry.io/docs/specs/semconv/runtime/jvm-metrics/#metric-jvmmemorylimit) | stable | UpDownCounter | jvm.memory.pool.name, jvm.memory.type | Max obtainable memory |
Expand All @@ -17,6 +17,7 @@ Those metrics are defined in the [JVM runtime metrics semantic conventions](http
| [jvm.class.count](https://opentelemetry.io/docs/specs/semconv/runtime/jvm-metrics/#metric-jvmclasscount) | stable | UpDownCounter | | Classes currently loaded count |
| [jvm.cpu.count](https://opentelemetry.io/docs/specs/semconv/runtime/jvm-metrics/#metric-jvmcpucount) | stable | UpDownCounter | | Number of CPUs available |
| [jvm.cpu.recent_utilization](https://opentelemetry.io/docs/specs/semconv/runtime/jvm-metrics/#metric-jvmcpurecent_utilization) | stable | Gauge | | Recent CPU utilization for process reported by JVM |
| [jvm.file_descriptor.count](https://opentelemetry.io/docs/specs/semconv/runtime/jvm-metrics/#metric-jvmfile_descriptorcount) | experimental | UpDownCounter | | Number of open file descriptors |
| [jvm.system.cpu.load_1m](https://opentelemetry.io/docs/specs/semconv/runtime/jvm-metrics/#metric-jvmsystemcpuload_1m) | experimental | Gauge | | Average CPU load reported by JVM |
| [jvm.system.cpu.recent_utilization](https://opentelemetry.io/docs/specs/semconv/runtime/jvm-metrics/#metric-jvmcpurecent_utilization) | experimental | Gauge | | Recent CPU utilization reported by JVM |
| [jvm.buffer.memory.used](https://opentelemetry.io/docs/specs/semconv/runtime/jvm-metrics/#metric-jvmbuffermemoryused) | experimental | UpDownCounter | jvm.buffer.pool.name | Memory used by buffers |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,12 @@ rules:
type: gauge
unit: '1'
desc: Recent CPU utilization for the whole system as reported by the JVM.
# jvm.file_descriptor.count (experimental)
OpenFileDescriptorCount:
metric: file_descriptor.count
type: updowncounter
unit: "{file_descriptors}"
desc: Number of open file descriptors.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

spec has Number of open file descriptors as reported by the JVM.


- bean: java.nio:name=*,type=BufferPool
prefix: jvm.buffer.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,14 @@ void testJvmMetrics(String image) {
.hasUnit("1")
.isGauge()
.hasDataPointsWithoutAttributes())
.add(
"jvm.file_descriptor.count",
metric ->
metric
.hasDescription("Number of open file descriptors.")
.hasUnit("{file_descriptors}")
.isUpDownCounter()
.hasDataPointsWithoutAttributes())
.add(
"jvm.system.cpu.load_1m",
metric ->
Expand Down
Loading