system: shared IO direction attributes (#530)

Co-authored-by: Alexander Wert <AlexanderWert@users.noreply.github.com>
This commit is contained in:
Braydon Kains 2023-11-22 05:25:58 -05:00 committed by GitHub
parent 04c8e49dc4
commit 34cc9485be
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 61 additions and 50 deletions

View File

@ -16,6 +16,7 @@ These attributes may be used for any network related operation.
| `network.carrier.name` | string | The name of the mobile carrier. | `sprint` | | `network.carrier.name` | string | The name of the mobile carrier. | `sprint` |
| `network.connection.subtype` | string | This describes more details regarding the connection.type. It may be the type of cell technology connection, but it could be used for describing details about a wifi connection. | `LTE` | | `network.connection.subtype` | string | This describes more details regarding the connection.type. It may be the type of cell technology connection, but it could be used for describing details about a wifi connection. | `LTE` |
| `network.connection.type` | string | The internet connection type. | `wifi` | | `network.connection.type` | string | The internet connection type. | `wifi` |
| `network.io.direction` | string | The network IO operation direction. | `transmit` |
| `network.local.address` | string | ![Stable](https://img.shields.io/badge/-stable-lightgreen)<br>Local address of the network connection - IP address or Unix domain socket name. | `10.1.2.80`; `/tmp/my.sock` | | `network.local.address` | string | ![Stable](https://img.shields.io/badge/-stable-lightgreen)<br>Local address of the network connection - IP address or Unix domain socket name. | `10.1.2.80`; `/tmp/my.sock` |
| `network.local.port` | int | ![Stable](https://img.shields.io/badge/-stable-lightgreen)<br>Local port number of the network connection. | `65123` | | `network.local.port` | int | ![Stable](https://img.shields.io/badge/-stable-lightgreen)<br>Local port number of the network connection. | `65123` |
| `network.peer.address` | string | ![Stable](https://img.shields.io/badge/-stable-lightgreen)<br>Peer address of the network connection - IP address or Unix domain socket name. | `10.1.2.80`; `/tmp/my.sock` | | `network.peer.address` | string | ![Stable](https://img.shields.io/badge/-stable-lightgreen)<br>Peer address of the network connection - IP address or Unix domain socket name. | `10.1.2.80`; `/tmp/my.sock` |
@ -73,6 +74,13 @@ different processes could be listening on TCP port 12345 and UDP port 12345.
| `unavailable` | unavailable | | `unavailable` | unavailable |
| `unknown` | unknown | | `unknown` | unknown |
`network.io.direction` MUST be one of the following:
| Value | Description |
|---|---|
| `transmit` | transmit |
| `receive` | receive |
`network.transport` has the following list of well-known values. If one of them applies, then the respective value MUST be used, otherwise a custom value MAY be used. `network.transport` has the following list of well-known values. If one of them applies, then the respective value MUST be used, otherwise a custom value MAY be used.
| Value | Description | | Value | Description |

View File

@ -359,10 +359,10 @@ This metric is [recommended][MetricRecommended].
<!-- semconv metric.system.disk.io(full) --> <!-- semconv metric.system.disk.io(full) -->
| Attribute | Type | Description | Examples | Requirement Level | | Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---| |---|---|---|---|---|
| `disk.io.direction` | string | The disk IO operation direction. | `read` | Recommended |
| `system.device` | string | The device identifier | `(identifier)` | Recommended | | `system.device` | string | The device identifier | `(identifier)` | Recommended |
| `system.disk.direction` | string | The disk operation direction | `read` | Recommended |
`system.disk.direction` MUST be one of the following: `disk.io.direction` MUST be one of the following:
| Value | Description | | Value | Description |
|---|---| |---|---|
@ -383,10 +383,10 @@ This metric is [recommended][MetricRecommended].
<!-- semconv metric.system.disk.operations(full) --> <!-- semconv metric.system.disk.operations(full) -->
| Attribute | Type | Description | Examples | Requirement Level | | Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---| |---|---|---|---|---|
| `disk.io.direction` | string | The disk IO operation direction. | `read` | Recommended |
| `system.device` | string | The device identifier | `(identifier)` | Recommended | | `system.device` | string | The device identifier | `(identifier)` | Recommended |
| `system.disk.direction` | string | The disk operation direction | `read` | Recommended |
`system.disk.direction` MUST be one of the following: `disk.io.direction` MUST be one of the following:
| Value | Description | | Value | Description |
|---|---| |---|---|
@ -435,10 +435,10 @@ This metric is [recommended][MetricRecommended].
<!-- semconv metric.system.disk.operation_time(full) --> <!-- semconv metric.system.disk.operation_time(full) -->
| Attribute | Type | Description | Examples | Requirement Level | | Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---| |---|---|---|---|---|
| `disk.io.direction` | string | The disk IO operation direction. | `read` | Recommended |
| `system.device` | string | The device identifier | `(identifier)` | Recommended | | `system.device` | string | The device identifier | `(identifier)` | Recommended |
| `system.disk.direction` | string | The disk operation direction | `read` | Recommended |
`system.disk.direction` MUST be one of the following: `disk.io.direction` MUST be one of the following:
| Value | Description | | Value | Description |
|---|---| |---|---|
@ -459,10 +459,10 @@ This metric is [recommended][MetricRecommended].
<!-- semconv metric.system.disk.merged(full) --> <!-- semconv metric.system.disk.merged(full) -->
| Attribute | Type | Description | Examples | Requirement Level | | Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---| |---|---|---|---|---|
| `disk.io.direction` | string | The disk IO operation direction. | `read` | Recommended |
| `system.device` | string | The device identifier | `(identifier)` | Recommended | | `system.device` | string | The device identifier | `(identifier)` | Recommended |
| `system.disk.direction` | string | The disk operation direction | `read` | Recommended |
`system.disk.direction` MUST be one of the following: `disk.io.direction` MUST be one of the following:
| Value | Description | | Value | Description |
|---|---| |---|---|
@ -575,10 +575,10 @@ This metric is [recommended][MetricRecommended].
<!-- semconv metric.system.network.dropped(full) --> <!-- semconv metric.system.network.dropped(full) -->
| Attribute | Type | Description | Examples | Requirement Level | | Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---| |---|---|---|---|---|
| [`network.io.direction`](../attributes-registry/network.md) | string | The network IO operation direction. | `transmit` | Recommended |
| `system.device` | string | The device identifier | `(identifier)` | Recommended | | `system.device` | string | The device identifier | `(identifier)` | Recommended |
| `system.network.direction` | string | | `transmit` | Recommended |
`system.network.direction` MUST be one of the following: `network.io.direction` MUST be one of the following:
| Value | Description | | Value | Description |
|---|---| |---|---|
@ -599,10 +599,10 @@ This metric is [recommended][MetricRecommended].
<!-- semconv metric.system.network.packets(full) --> <!-- semconv metric.system.network.packets(full) -->
| Attribute | Type | Description | Examples | Requirement Level | | Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---| |---|---|---|---|---|
| [`network.io.direction`](../attributes-registry/network.md) | string | The network IO operation direction. | `transmit` | Recommended |
| `system.device` | string | The device identifier | `(identifier)` | Recommended | | `system.device` | string | The device identifier | `(identifier)` | Recommended |
| `system.network.direction` | string | | `transmit` | Recommended |
`system.network.direction` MUST be one of the following: `network.io.direction` MUST be one of the following:
| Value | Description | | Value | Description |
|---|---| |---|---|
@ -629,10 +629,10 @@ This metric is [recommended][MetricRecommended].
<!-- semconv metric.system.network.errors(full) --> <!-- semconv metric.system.network.errors(full) -->
| Attribute | Type | Description | Examples | Requirement Level | | Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---| |---|---|---|---|---|
| [`network.io.direction`](../attributes-registry/network.md) | string | The network IO operation direction. | `transmit` | Recommended |
| `system.device` | string | The device identifier | `(identifier)` | Recommended | | `system.device` | string | The device identifier | `(identifier)` | Recommended |
| `system.network.direction` | string | | `transmit` | Recommended |
`system.network.direction` MUST be one of the following: `network.io.direction` MUST be one of the following:
| Value | Description | | Value | Description |
|---|---| |---|---|
@ -653,10 +653,10 @@ This metric is [recommended][MetricRecommended].
<!-- semconv metric.system.network.io(full) --> <!-- semconv metric.system.network.io(full) -->
| Attribute | Type | Description | Examples | Requirement Level | | Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---| |---|---|---|---|---|
| [`network.io.direction`](../attributes-registry/network.md) | string | The network IO operation direction. | `transmit` | Recommended |
| `system.device` | string | The device identifier | `(identifier)` | Recommended | | `system.device` | string | The device identifier | `(identifier)` | Recommended |
| `system.network.direction` | string | | `transmit` | Recommended |
`system.network.direction` MUST be one of the following: `network.io.direction` MUST be one of the following:
| Value | Description | | Value | Description |
|---|---| |---|---|

View File

@ -213,22 +213,6 @@ groups:
- ref: system.paging.direction - ref: system.paging.direction
# system.disk.* metrics and attribute group # system.disk.* metrics and attribute group
- id: attributes.system.disk
prefix: system.disk
type: attribute_group
brief: "Describes System Disk metric attributes"
attributes:
- id: direction
type:
allow_custom_values: false
members:
- id: read
value: 'read'
- id: write
value: 'write'
brief: "The disk operation direction"
examples: ["read"]
- id: metric.system.disk.io - id: metric.system.disk.io
type: metric type: metric
metric_name: system.disk.io metric_name: system.disk.io
@ -237,7 +221,7 @@ groups:
unit: "By" unit: "By"
attributes: attributes:
- ref: system.device - ref: system.device
- ref: system.disk.direction - ref: disk.io.direction
- id: metric.system.disk.operations - id: metric.system.disk.operations
type: metric type: metric
@ -247,7 +231,7 @@ groups:
unit: "{operation}" unit: "{operation}"
attributes: attributes:
- ref: system.device - ref: system.device
- ref: system.disk.direction - ref: disk.io.direction
- id: metric.system.disk.io_time - id: metric.system.disk.io_time
type: metric type: metric
@ -278,7 +262,7 @@ groups:
- Windows: "Avg. Disk sec/Read" perf counter multiplied by "Disk Reads/sec" perf counter (similar for Writes) - Windows: "Avg. Disk sec/Read" perf counter multiplied by "Disk Reads/sec" perf counter (similar for Writes)
attributes: attributes:
- ref: system.device - ref: system.device
- ref: system.disk.direction - ref: disk.io.direction
- id: metric.system.disk.merged - id: metric.system.disk.merged
type: metric type: metric
@ -288,7 +272,7 @@ groups:
unit: "{operation}" unit: "{operation}"
attributes: attributes:
- ref: system.device - ref: system.device
- ref: system.disk.direction - ref: disk.io.direction
# system.filesystem.* metrics and attribute group # system.filesystem.* metrics and attribute group
- id: attributes.system.filesystem - id: attributes.system.filesystem
@ -362,21 +346,13 @@ groups:
- ref: system.filesystem.mountpoint - ref: system.filesystem.mountpoint
# system.network.* metrics and attribute group # system.network.* metrics and attribute group
# System-specific network attributes
- id: attributes.system.network - id: attributes.system.network
prefix: system.network prefix: system.network
type: attribute_group type: attribute_group
brief: "Describes Network metric attributes" brief: "Describes Network metric attributes"
attributes: attributes:
- id: direction
type:
allow_custom_values: false
members:
- id: transmit
value: 'transmit'
- id: receive
value: 'receive'
brief: ""
examples: ["transmit"]
- id: state - id: state
type: type:
allow_custom_values: false allow_custom_values: false
@ -422,7 +398,7 @@ groups:
from [`GetIfEntry2`](https://docs.microsoft.com/windows/win32/api/netioapi/nf-netioapi-getifentry2) from [`GetIfEntry2`](https://docs.microsoft.com/windows/win32/api/netioapi/nf-netioapi-getifentry2)
attributes: attributes:
- ref: system.device - ref: system.device
- ref: system.network.direction - ref: network.io.direction
- id: metric.system.network.packets - id: metric.system.network.packets
type: metric type: metric
@ -432,7 +408,7 @@ groups:
unit: "{packet}" unit: "{packet}"
attributes: attributes:
- ref: system.device - ref: system.device
- ref: system.network.direction - ref: network.io.direction
- id: metric.system.network.errors - id: metric.system.network.errors
type: metric type: metric
@ -448,7 +424,7 @@ groups:
from [`GetIfEntry2`](https://docs.microsoft.com/windows/win32/api/netioapi/nf-netioapi-getifentry2). from [`GetIfEntry2`](https://docs.microsoft.com/windows/win32/api/netioapi/nf-netioapi-getifentry2).
attributes: attributes:
- ref: system.device - ref: system.device
- ref: system.network.direction - ref: network.io.direction
- id: metric.system.network.io - id: metric.system.network.io
type: metric type: metric
@ -458,7 +434,7 @@ groups:
unit: "By" unit: "By"
attributes: attributes:
- ref: system.device - ref: system.device
- ref: system.network.direction - ref: network.io.direction
- id: metric.system.network.connections - id: metric.system.network.connections
type: metric type: metric

17
model/registry/disk.yaml Normal file
View File

@ -0,0 +1,17 @@
groups:
- id: registry.disk
prefix: disk
type: attribute_group
brief: >
These attributes may be used for any disk related operation.
attributes:
- id: io.direction
type:
allow_custom_values: false
members:
- id: read
value: 'read'
- id: write
value: 'write'
brief: "The disk IO operation direction."
examples: ["read"]

View File

@ -182,3 +182,13 @@ groups:
brief: '[OSI network layer](https://osi-model.com/network-layer/) or non-OSI equivalent.' brief: '[OSI network layer](https://osi-model.com/network-layer/) or non-OSI equivalent.'
note: The value SHOULD be normalized to lowercase. note: The value SHOULD be normalized to lowercase.
examples: ['ipv4', 'ipv6'] examples: ['ipv4', 'ipv6']
- id: io.direction
type:
allow_custom_values: false
members:
- id: transmit
value: 'transmit'
- id: receive
value: 'receive'
brief: "The network IO operation direction."
examples: ["transmit"]