Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add JVM runtime metric source API notes #3463

Merged
merged 25 commits into from
May 8, 2023
Merged
Changes from 18 commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
eac18a0
add notes for apis
roberttoyonaga May 2, 2023
d97fb8d
apply review feedback and fix gate tests
roberttoyonaga May 3, 2023
d0eb365
add notes for apis
roberttoyonaga May 2, 2023
677765d
apply review feedback and fix gate tests
roberttoyonaga May 3, 2023
5f88dd2
Update specification/metrics/semantic_conventions/runtime-environment…
roberttoyonaga May 4, 2023
b5cc911
Update specification/metrics/semantic_conventions/runtime-environment…
roberttoyonaga May 4, 2023
b46e929
Update specification/metrics/semantic_conventions/runtime-environment…
roberttoyonaga May 4, 2023
33b6c42
Update specification/metrics/semantic_conventions/runtime-environment…
roberttoyonaga May 4, 2023
bc29824
Update specification/metrics/semantic_conventions/runtime-environment…
roberttoyonaga May 4, 2023
d674de1
Update specification/metrics/semantic_conventions/runtime-environment…
roberttoyonaga May 4, 2023
92bb45c
Update specification/metrics/semantic_conventions/runtime-environment…
roberttoyonaga May 4, 2023
8b1e96f
Update specification/metrics/semantic_conventions/runtime-environment…
roberttoyonaga May 4, 2023
4890b4f
Update specification/metrics/semantic_conventions/runtime-environment…
roberttoyonaga May 4, 2023
ef0bb2d
Update specification/metrics/semantic_conventions/runtime-environment…
roberttoyonaga May 4, 2023
a1df939
Update specification/metrics/semantic_conventions/runtime-environment…
roberttoyonaga May 4, 2023
0138e92
Update specification/metrics/semantic_conventions/runtime-environment…
roberttoyonaga May 4, 2023
58eba72
Update specification/metrics/semantic_conventions/runtime-environment…
roberttoyonaga May 4, 2023
75ff452
Update specification/metrics/semantic_conventions/runtime-environment…
roberttoyonaga May 4, 2023
db39ee8
Update specification/metrics/semantic_conventions/runtime-environment…
roberttoyonaga May 4, 2023
a35b237
Update specification/metrics/semantic_conventions/runtime-environment…
roberttoyonaga May 4, 2023
9c8762d
update links to english and add more info for GC duration
roberttoyonaga May 5, 2023
b9030c0
fix conflicts
roberttoyonaga May 5, 2023
3d409b8
changelog
roberttoyonaga May 8, 2023
42092ef
Merge branch 'main' into api-links
trask May 8, 2023
acd7043
Merge branch 'main' into api-links
jack-berg May 8, 2023
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
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ consider, for example pthreads vs green thread implementations.
### Metric: `process.runtime.jvm.memory.usage`

This metric is [recommended](../metric-requirement-level.md#recommended).
This metric is obtained from [`MemoryPoolMXBean#getUsage()`](https://docs.oracle.com/javase/8/docs/api/java/lang/management/MemoryPoolMXBean.html#getUsage--).

<!-- semconv metric.process.runtime.jvm.memory.usage(metric_table) -->
| Name | Instrument Type | Unit (UCUM) | Description |
Expand All @@ -104,6 +105,7 @@ This metric is [recommended](../metric-requirement-level.md#recommended).
### Metric: `process.runtime.jvm.memory.init`

This metric is [recommended](../metric-requirement-level.md#recommended).
This metric is obtained from [`MemoryPoolMXBean#getUsage()`](https://docs.oracle.com/javase/8/docs/api/java/lang/management/MemoryPoolMXBean.html#getUsage--).

<!-- semconv metric.process.runtime.jvm.memory.init(metric_table) -->
| Name | Instrument Type | Unit (UCUM) | Description |
Expand All @@ -130,6 +132,7 @@ This metric is [recommended](../metric-requirement-level.md#recommended).
### Metric: `process.runtime.jvm.memory.committed`

This metric is [recommended](../metric-requirement-level.md#recommended).
This metric is obtained from [`MemoryPoolMXBean#getUsage()`](https://docs.oracle.com/javase/8/docs/api/java/lang/management/MemoryPoolMXBean.html#getUsage--).

<!-- semconv metric.process.runtime.jvm.memory.committed(metric_table) -->
| Name | Instrument Type | Unit (UCUM) | Description |
Expand All @@ -156,6 +159,7 @@ This metric is [recommended](../metric-requirement-level.md#recommended).
### Metric: `process.runtime.jvm.memory.limit`

This metric is [recommended](../metric-requirement-level.md#recommended).
This metric is obtained from [`MemoryPoolMXBean#getUsage()`](https://docs.oracle.com/javase/8/docs/api/java/lang/management/MemoryPoolMXBean.html#getUsage--).

<!-- semconv metric.process.runtime.jvm.memory.limit(metric_table) -->
| Name | Instrument Type | Unit (UCUM) | Description |
Expand All @@ -182,6 +186,7 @@ This metric is [recommended](../metric-requirement-level.md#recommended).
### Metric: `process.runtime.jvm.memory.usage_after_last_gc`

This metric is [recommended](../metric-requirement-level.md#recommended).
This metric is obtained from [`MemoryPoolMXBean#getCollectionUsage()`](https://docs.oracle.com/javase/8/docs/api/java/lang/management/MemoryPoolMXBean.html#getCollectionUsage--).

<!-- semconv metric.process.runtime.jvm.memory.usage_after_last_gc(metric_table) -->
| Name | Instrument Type | Unit (UCUM) | Description |
Expand All @@ -208,6 +213,7 @@ This metric is [recommended](../metric-requirement-level.md#recommended).
### Metric: `process.runtime.jvm.gc.duration`

This metric is [recommended](../metric-requirement-level.md#recommended).
This metric is obtained from [`GarbageCollectorMXBean`](https://docs.oracle.com/javase/8/docs/api/java/lang/management/GarbageCollectorMXBean.html).
trask marked this conversation as resolved.
Show resolved Hide resolved

This metric SHOULD be specified with
[`ExplicitBucketBoundaries`](../../metrics/api.md#instrument-advice)
Expand All @@ -233,6 +239,8 @@ of `[]` (single bucket histogram capturing count, sum, min, max).
### Metric: `process.runtime.jvm.threads.count`

This metric is [recommended](../metric-requirement-level.md#recommended).
This metric is obtained from [`ThreadMXBean#getDaemonThreadCount()`](https://docs.oracle.com/javase/8/docs/api/java/lang/management/ThreadMXBean.html#getDaemonThreadCount--) and
[`ThreadMXBean#getThreadCount()`](https://docs.oracle.com/javase/8/docs/api/java/lang/management/ThreadMXBean.html#getThreadCount--).

<!-- semconv metric.process.runtime.jvm.threads.count(metric_table) -->
| Name | Instrument Type | Unit (UCUM) | Description |
Expand All @@ -249,6 +257,7 @@ This metric is [recommended](../metric-requirement-level.md#recommended).
### Metric: `process.runtime.jvm.classes.loaded`

This metric is [recommended](../metric-requirement-level.md#recommended).
This metric is obtained from [`ClassLoadingMXBean#getTotalLoadedClassCount()`](https://docs.oracle.com/javase/8/docs/api/java/lang/management/ClassLoadingMXBean.html#getTotalLoadedClassCount--).

<!-- semconv metric.process.runtime.jvm.classes.loaded(metric_table) -->
| Name | Instrument Type | Unit (UCUM) | Description |
Expand All @@ -262,6 +271,7 @@ This metric is [recommended](../metric-requirement-level.md#recommended).
### Metric: `process.runtime.jvm.classes.unloaded`

This metric is [recommended](../metric-requirement-level.md#recommended).
This metric is obtained from [`ClassLoadingMXBean#getUnloadedClassCount()`](https://docs.oracle.com/javase/8/docs/api/java/lang/management/ClassLoadingMXBean.html#getUnloadedClassCount--).

<!-- semconv metric.process.runtime.jvm.classes.unloaded(metric_table) -->
| Name | Instrument Type | Unit (UCUM) | Description |
Expand All @@ -275,6 +285,7 @@ This metric is [recommended](../metric-requirement-level.md#recommended).
### Metric: `process.runtime.jvm.classes.current_loaded`

This metric is [recommended](../metric-requirement-level.md#recommended).
This metric is obtained from [`ClassLoadingMXBean#getLoadedClassCount()`](https://docs.oracle.com/javase/8/docs/api/java/lang/management/ClassLoadingMXBean.html#getLoadedClassCount--).

<!-- semconv metric.process.runtime.jvm.classes.current_loaded(metric_table) -->
| Name | Instrument Type | Unit (UCUM) | Description |
Expand All @@ -288,6 +299,8 @@ This metric is [recommended](../metric-requirement-level.md#recommended).
### Metric: `process.runtime.jvm.cpu.utilization`

This metric is [recommended](../metric-requirement-level.md#recommended).
This metric is obtained from [`com.sun.management.OperatingSystemMXBean#getProcessCpuLoad()`](https://docs.oracle.com/en/java/javase/17/docs/api/jdk.management/com/sun/management/OperatingSystemMXBean.html#getProcessCpuLoad()) on HotSpot
and [`com.ibm.lang.management.OperatingSystemMXBean#getCpuLoad()`](https://www.ibm.com/docs/hr/sdk-java-technology/8?topic=SSYKE2_8.0.0/openj9/api/jdk8/jre/management/extension/com/ibm/lang/management/OperatingSystemMXBean.htm) on J9.

<!-- semconv metric.process.runtime.jvm.cpu.utilization(metric_table) -->
| Name | Instrument Type | Unit (UCUM) | Description |
Expand All @@ -301,6 +314,8 @@ This metric is [recommended](../metric-requirement-level.md#recommended).
### Metric: `process.runtime.jvm.system.cpu.utilization`

This metric is [recommended](../metric-requirement-level.md#recommended).
This metric is obtained from [`com.sun.management.OperatingSystemMXBean#getSystemCpuLoad()`](https://docs.oracle.com/en/java/javase/17/docs/api/jdk.management/com/sun/management/OperatingSystemMXBean.html#getSystemCpuLoad()) on Java version 8..13, [`com.sun.management.OperatingSystemMXBean#getCpuLoad()`](https://docs.oracle.com/en/java/javase/17/docs/api/jdk.management/com/sun/management/OperatingSystemMXBean.html#getCpuLoad()) on Java version 14+,
and [`com.ibm.lang.management.OperatingSystemMXBean#getCpuLoad()`](https://www.ibm.com/docs/hr/sdk-java-technology/8?topic=SSYKE2_8.0.0/openj9/api/jdk8/jre/management/extension/com/ibm/lang/management/OperatingSystemMXBean.htm) on J9.
trask marked this conversation as resolved.
Show resolved Hide resolved

<!-- semconv metric.process.runtime.jvm.system.cpu.utilization(metric_table) -->
| Name | Instrument Type | Unit (UCUM) | Description |
Expand All @@ -314,6 +329,7 @@ This metric is [recommended](../metric-requirement-level.md#recommended).
### Metric: `process.runtime.jvm.system.cpu.load_1m`

This metric is [recommended](../metric-requirement-level.md#recommended).
This metric is obtained from [`OperatingSystemMXBean#getSystemLoadAverage()`](https://docs.oracle.com/javase/8/docs/api/java/lang/management/OperatingSystemMXBean.html#getSystemLoadAverage--).

<!-- semconv metric.process.runtime.jvm.system.cpu.load_1m(metric_table) -->
| Name | Instrument Type | Unit (UCUM) | Description |
Expand All @@ -327,6 +343,7 @@ This metric is [recommended](../metric-requirement-level.md#recommended).
### Metric: `process.runtime.jvm.buffer.usage`

This metric is [recommended](../metric-requirement-level.md#recommended).
This metric is obtained from [`BufferPoolMXBean#getMemoryUsed()`](https://docs.oracle.com/javase/8/docs/api/java/lang/management/BufferPoolMXBean.html#getMemoryUsed--).

<!-- semconv metric.process.runtime.jvm.buffer.usage(metric_table) -->
| Name | Instrument Type | Unit (UCUM) | Description |
Expand All @@ -345,6 +362,7 @@ This metric is [recommended](../metric-requirement-level.md#recommended).
### Metric: `process.runtime.jvm.buffer.limit`

This metric is [recommended](../metric-requirement-level.md#recommended).
This metric is obtained from [`BufferPoolMXBean#getTotalCapacity()`](https://docs.oracle.com/javase/8/docs/api/java/lang/management/BufferPoolMXBean.html#getTotalCapacity--).

<!-- semconv metric.process.runtime.jvm.buffer.limit(metric_table) -->
| Name | Instrument Type | Unit (UCUM) | Description |
Expand All @@ -363,6 +381,7 @@ This metric is [recommended](../metric-requirement-level.md#recommended).
### Metric: `process.runtime.jvm.buffer.count`

This metric is [recommended](../metric-requirement-level.md#recommended).
This metric is obtained from [`BufferPoolMXBean#getCount()`](https://docs.oracle.com/javase/8/docs/api/java/lang/management/BufferPoolMXBean.html#getCount--).

<!-- semconv metric.process.runtime.jvm.buffer.count(metric_table) -->
| Name | Instrument Type | Unit (UCUM) | Description |
Expand Down