Skip to content

Commit

Permalink
Update hardware group name to match metric_name (#1457)
Browse files Browse the repository at this point in the history
  • Loading branch information
lmolkova authored Oct 7, 2024
1 parent 8d2ab74 commit b42dfbd
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 14 deletions.
10 changes: 5 additions & 5 deletions docs/hardware/common.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ The below metrics apply to any type of hardware component.

These common `hw.` metrics include the below attributes to describe the
monitored component:
<!-- semconv metric.hardware.attributes -->
<!-- semconv metric.hw.attributes -->
<!-- NOTE: THIS TEXT IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
<!-- see templates/registry/markdown/snippet.md.j2 -->
<!-- prettier-ignore-start -->
Expand Down Expand Up @@ -74,7 +74,7 @@ monitored component:

This metric is [recommended][MetricRecommended].

<!-- semconv metric.hardware.energy -->
<!-- semconv metric.hw.energy -->
<!-- NOTE: THIS TEXT IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
<!-- see templates/registry/markdown/snippet.md.j2 -->
<!-- prettier-ignore-start -->
Expand Down Expand Up @@ -126,7 +126,7 @@ This metric is [recommended][MetricRecommended].

This metric is [recommended][MetricRecommended].

<!-- semconv metric.hardware.errors -->
<!-- semconv metric.hw.errors -->
<!-- NOTE: THIS TEXT IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
<!-- see templates/registry/markdown/snippet.md.j2 -->
<!-- prettier-ignore-start -->
Expand Down Expand Up @@ -188,7 +188,7 @@ This metric is [recommended][MetricRecommended].

This metric is [recommended][MetricRecommended].

<!-- semconv metric.hardware.power -->
<!-- semconv metric.hw.power -->
<!-- NOTE: THIS TEXT IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
<!-- see templates/registry/markdown/snippet.md.j2 -->
<!-- prettier-ignore-start -->
Expand Down Expand Up @@ -244,7 +244,7 @@ This metric is [recommended][MetricRecommended].

This metric is [recommended][MetricRecommended].

<!-- semconv metric.hardware.status -->
<!-- semconv metric.hw.status -->
<!-- NOTE: THIS TEXT IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
<!-- see templates/registry/markdown/snippet.md.j2 -->
<!-- prettier-ignore-start -->
Expand Down
18 changes: 9 additions & 9 deletions model/hardware/common-metrics.yaml
Original file line number Diff line number Diff line change
@@ -1,30 +1,30 @@
groups:
# COMMON METRICS
- id: metric.hardware.attributes
- id: metric.hw.attributes
type: attribute_group
brief: "Attributes for hardware metrics"
extends: hardware.attributes.common
attributes:
- ref: hw.type
requirement_level: required

- id: metric.hardware.energy
- id: metric.hw.energy
type: metric
metric_name: hw.energy
stability: experimental
brief: "Energy consumed by the component"
instrument: counter
unit: "J"
extends: metric.hardware.attributes
extends: metric.hw.attributes

- id: metric.hardware.errors
- id: metric.hw.errors
type: metric
metric_name: hw.errors
stability: experimental
brief: "Number of errors encountered by the component"
instrument: counter
unit: "{error}"
extends: metric.hardware.attributes
extends: metric.hw.attributes
attributes:
- ref: error.type
brief: "The type of error encountered by the component"
Expand All @@ -35,7 +35,7 @@ groups:
The `error.type` SHOULD match the error code reported by the component, the canonical name of the error,
or another low-cardinality error identifier. Instrumentations SHOULD document the list of errors they report.
- id: metric.hardware.power
- id: metric.hw.power
type: metric
metric_name: hw.power
stability: experimental
Expand All @@ -44,16 +44,16 @@ groups:
It is recommended to report `hw.energy` instead of `hw.power` when possible.
instrument: gauge
unit: "W"
extends: metric.hardware.attributes
extends: metric.hw.attributes

- id: metric.hardware.status
- id: metric.hw.status
type: metric
metric_name: hw.status
stability: experimental
brief: "Operational status: `1` (true) or `0` (false) for each of the possible states"
instrument: updowncounter
unit: "1"
extends: metric.hardware.attributes
extends: metric.hw.attributes
note: >
`hw.status` is currently specified as an *UpDownCounter* but would ideally be represented using a
[*StateSet* as defined in OpenMetrics](https://github.com/OpenObservability/OpenMetrics/blob/main/specification/OpenMetrics.md#stateset).
Expand Down

0 comments on commit b42dfbd

Please sign in to comment.