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

Update semconv for hardware metrics to use direction attributes #2942

Merged
merged 2 commits into from
Dec 5, 2022
Merged
Show file tree
Hide file tree
Changes from all 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
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ release.
([#2981](https://github.com/open-telemetry/opentelemetry-specification/pull/2981))
- Add `messaging.kafka.message.offset` attribute.
([#2982](https://github.com/open-telemetry/opentelemetry-specification/pull/2982))
- Update hardware metrics to use `direction` as per general semantic conventions
([#2942](https://github.com/open-telemetry/opentelemetry-specification/pull/2942))

### Compatibility

Expand Down
49 changes: 23 additions & 26 deletions specification/metrics/semantic_conventions/hardware-metrics.md
Original file line number Diff line number Diff line change
Expand Up @@ -189,19 +189,18 @@ Additional **optional** attributes:

**Description:** Graphics Processing Unit (discrete)

| Name | Description | Units | Instrument Type ([*](README.md#instrument-types)) | Value Type | Attribute Key | Attribute Values |
| --------------------------- | ----------------------------------------------------------------------------- | -------- | ------------------------------------------------- | ---------- | -------------------- | ----------------------------------------------- |
| `hw.errors` | Number of errors encountered by the GPU | {errors} | Counter | Int64 | `type` (recommended) | `corrected`, `all` |
| | | | | | `hw.type` (required) | `gpu` |
| `hw.gpu.io.receive` | Received bytes by the GPU | By | Counter | Int64 | | |
| `hw.gpu.io.transmit` | Transmitted bytes by the GPU | By | Counter | Int64 | | |
| `hw.gpu.memory.limit` | Size of the GPU memory | By | UpDownCounter | Int64 | | |
| `hw.gpu.memory.utilization` | Fraction of GPU memory used | 1 | Gauge | Double | | |
| `hw.gpu.memory.usage` | GPU memory used | By | UpDownCounter | Int64 | | |
| `hw.gpu.power` | GPU instantaneous power consumption in Watts | W | Gauge | Double | | |
| `hw.gpu.utilization` | Fraction of time spent in a specific task | 1 | Gauge | Double | `task` (recommended) | `decoder`, `encoder`, `general` |
| `hw.status` | Operational status: `1` (true) or `0` (false) for each of the possible states | | UpDownCounter | Int | `state` (required) | `ok`, `degraded`, `failed`, `predicted_failure` |
| | | | | | `hw.type` (required) | `gpu` |
| Name | Description | Units | Instrument Type ([*](README.md#instrument-types)) | Value Type | Attribute Key | Attribute Values |
| --------------------------- | ----------------------------------------------------------------------------- | -------- | ------------------------------------------------- | ---------- | ---------------------- | ----------------------------------------------- |
| `hw.errors` | Number of errors encountered by the GPU | {errors} | Counter | Int64 | `type` (recommended) | `corrected`, `all` |
| | | | | | `hw.type` (required) | `gpu` |
| `hw.gpu.io` | Received and transmitted bytes by the GPU | By | Counter | Int64 | `direction` (required) | `receive`, `transmit` |
| `hw.gpu.memory.limit` | Size of the GPU memory | By | UpDownCounter | Int64 | | |
| `hw.gpu.memory.utilization` | Fraction of GPU memory used | 1 | Gauge | Double | | |
| `hw.gpu.memory.usage` | GPU memory used | By | UpDownCounter | Int64 | | |
| `hw.gpu.power` | GPU instantaneous power consumption in Watts | W | Gauge | Double | | |
| `hw.gpu.utilization` | Fraction of time spent in a specific task | 1 | Gauge | Double | `task` (recommended) | `decoder`, `encoder`, `general` |
| `hw.status` | Operational status: `1` (true) or `0` (false) for each of the possible states | | UpDownCounter | Int | `state` (required) | `ok`, `degraded`, `failed`, `predicted_failure` |
| | | | | | `hw.type` (required) | `gpu` |

Additional **optional** attributes:

Expand Down Expand Up @@ -260,19 +259,17 @@ Additional **optional** attributes:
(NIC), excluding virtual adapters and loopbacks. Examples: an Ethernet adapter,
an HBA, an fiber channel port or a Wi-Fi adapter.

| Name | Description | Units | Instrument Type ([*](README.md#instrument-types)) | Value Type | Attribute Key | Attribute Values |
| ---------------------------------- | ------------------------------------------------------------------------------------------------------------ | --------- | ------------------------------------------------- | ---------- | -------------------- | --------------------------- |
| `hw.errors` | Number of errors encountered by the network adapter | {errors} | Counter | Int64 | `type` (recommended) | `all`, `zero_buffer_credit` |
| | | | | | `hw.type` (required) | `network` |
| `hw.network.bandwidth.limit` | Link speed | By | UpDownCounter | Int64 | | |
| `hw.network.bandwidth.utilization` | Utilization of the network bandwidth as a fraction | 1 | Gauge | Double | | |
| `hw.network.io.receive` | Received network traffic in bytes | By | Counter | Int64 | | |
| `hw.network.io.transmit` | Transmitted network traffic in bytes | By | Counter | Int64 | | |
| `hw.network.packets.receive` | Received network traffic in packets (or frames) | {packets} | Counter | Int64 | | |
| `hw.network.packets.transmit` | Transmitted network traffic in packets (or frames) | {packets} | Counter | Int64 | | |
| `hw.network.up` | Link status: `1` (up) or `0` (down) | | UpDownCounter | Int | | |
| `hw.status` | Operational status, regardless of the link status: `1` (true) or `0` (false) for each of the possible states | | UpDownCounter | Int | `state` (required) | `ok`, `degraded`, `failed` |
| | | | | | `hw.type` (required) | `network` |
| Name | Description | Units | Instrument Type ([*](README.md#instrument-types)) | Value Type | Attribute Key | Attribute Values |
| ---------------------------------- | ------------------------------------------------------------------------------------------------------------ | --------- | ------------------------------------------------- | ---------- | ---------------------- | --------------------------- |
| `hw.errors` | Number of errors encountered by the network adapter | {errors} | Counter | Int64 | `type` (recommended) | `all`, `zero_buffer_credit` |
| | | | | | `hw.type` (required) | `network` |
| `hw.network.bandwidth.limit` | Link speed | By | UpDownCounter | Int64 | | |
| `hw.network.bandwidth.utilization` | Utilization of the network bandwidth as a fraction | 1 | Gauge | Double | | |
| `hw.network.io` | Received and transmitted network traffic in bytes | By | Counter | Int64 | `direction` (required) | `receive`, `transmit` |
| `hw.network.packets` | Received and transmitted network traffic in packets (or frames) | {packets} | Counter | Int64 | `direction` (required) | `receive`, `transmit` |
| `hw.network.up` | Link status: `1` (up) or `0` (down) | | UpDownCounter | Int | | |
| `hw.status` | Operational status, regardless of the link status: `1` (true) or `0` (false) for each of the possible states | | UpDownCounter | Int | `state` (required) | `ok`, `degraded`, `failed` |
| | | | | | `hw.type` (required) | `network` |

Additional **optional** attributes:

Expand Down