Skip to content

Commit

Permalink
Add system.device attribute to system paging metrics (#1408)
Browse files Browse the repository at this point in the history
Co-authored-by: Joao Grassi <[email protected]>
  • Loading branch information
rogercoll and joaopgrassi authored Oct 15, 2024
1 parent 76112dd commit d89ada7
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 0 deletions.
22 changes: 22 additions & 0 deletions .chloggen/add_paging_device_attr.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Use this changelog template to create an entry for release notes.
#
# If your change doesn't affect end users you should instead start
# your pull request title with [chore] or use the "Skip Changelog" label.

# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
change_type: 'breaking'

# The name of the area of concern in the attributes-registry, (e.g. http, cloud, db)
component: system

# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Add system.device attribute to system paging metrics

# Mandatory: One or more tracking issues related to the change. You can use the PR number here if no issue exists.
# The values here must be integers.
issues: [1408]

# (Optional) One or more lines of additional information to render under the primary note.
# These lines will be padded with 2 spaces and then inserted directly into the document.
# Use pipe (|) for multiline entries.
subtext:
2 changes: 2 additions & 0 deletions docs/system/system-metrics.md
Original file line number Diff line number Diff line change
Expand Up @@ -384,6 +384,7 @@ This metric is [recommended][MetricRecommended].

| Attribute | Type | Description | Examples | [Requirement Level](https://opentelemetry.io/docs/specs/semconv/general/attribute-requirement-level/) | Stability |
|---|---|---|---|---|---|
| [`system.device`](/docs/attributes-registry/system.md) | string | Unique identifier for the device responsible for managing paging operations. | `/dev/dm-0` | `Recommended` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| [`system.paging.state`](/docs/attributes-registry/system.md) | string | The memory paging state | `free` | `Recommended` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |

`system.paging.state` 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.
Expand Down Expand Up @@ -417,6 +418,7 @@ This metric is [recommended][MetricRecommended].

| Attribute | Type | Description | Examples | [Requirement Level](https://opentelemetry.io/docs/specs/semconv/general/attribute-requirement-level/) | Stability |
|---|---|---|---|---|---|
| [`system.device`](/docs/attributes-registry/system.md) | string | Unique identifier for the device responsible for managing paging operations. | `/dev/dm-0` | `Recommended` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| [`system.paging.state`](/docs/attributes-registry/system.md) | string | The memory paging state | `free` | `Recommended` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |

`system.paging.state` 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.
Expand Down
6 changes: 6 additions & 0 deletions model/system/metrics.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,9 @@ groups:
unit: "By"
attributes:
- ref: system.paging.state
- ref: system.device
brief: Unique identifier for the device responsible for managing paging operations.
examples: ["/dev/dm-0"]

- id: metric.system.paging.utilization
type: metric
Expand All @@ -120,6 +123,9 @@ groups:
unit: "1"
attributes:
- ref: system.paging.state
- ref: system.device
brief: Unique identifier for the device responsible for managing paging operations.
examples: ["/dev/dm-0"]

- id: metric.system.paging.faults
type: metric
Expand Down

0 comments on commit d89ada7

Please sign in to comment.