From f6fec98892f1b7a1e92b2cfff0812c40f6195c1e Mon Sep 17 00:00:00 2001 From: Pablo Baeyens Date: Mon, 13 Nov 2023 12:23:30 +0100 Subject: [PATCH] [model/resource] Change `host.cpu.model.family` and `host.cpu.model.id` to be strings (#499) Co-authored-by: Joao Grassi --- CHANGELOG.md | 2 ++ docs/resource/host.md | 4 ++-- model/resource/host.yaml | 10 +++++----- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 60a2c8c822..f2657cb0ce 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,8 @@ release. - Update `jvm.gc.duration` histogram buckets to `[ 0.01, 0.1, 1, 10 ]` ([#317](https://github.com/open-telemetry/semantic-conventions/pull/317)) +- BREAKING: Change type of `host.cpu.model.id` and `host.cpu.model.family` to string. + ([#495](https://github.com/open-telemetry/semantic-conventions/issues/495)) ### Features diff --git a/docs/resource/host.md b/docs/resource/host.md index f7e2286af5..3bfedb3715 100644 --- a/docs/resource/host.md +++ b/docs/resource/host.md @@ -46,8 +46,8 @@ To report host metrics, the `system.*` namespace SHOULD be used. | Attribute | Type | Description | Examples | Requirement Level | |---|---|---|---|---| | `host.cpu.cache.l2.size` | int | The amount of level 2 memory cache available to the processor (in Bytes). | `12288000` | Opt-In | -| `host.cpu.family` | int | Numeric value specifying the family or generation of the CPU. | `6` | Opt-In | -| `host.cpu.model.id` | int | Model identifier. It provides more granular information about the CPU, distinguishing it from other CPUs within the same family. | `6` | Opt-In | +| `host.cpu.family` | string | Family or generation of the CPU. | `6`; `PA-RISC 1.1e` | Opt-In | +| `host.cpu.model.id` | string | Model identifier. It provides more granular information about the CPU, distinguishing it from other CPUs within the same family. | `6`; `9000/778/B180L` | Opt-In | | `host.cpu.model.name` | string | Model designation of the processor. | `11th Gen Intel(R) Core(TM) i7-1185G7 @ 3.00GHz` | Opt-In | | `host.cpu.stepping` | int | Stepping or core revisions. | `1` | Opt-In | | `host.cpu.vendor.id` | string | Processor manufacturer identifier. A maximum 12-character string. [1] | `GenuineIntel` | Opt-In | diff --git a/model/resource/host.yaml b/model/resource/host.yaml index 9b63976db5..9665d09c58 100644 --- a/model/resource/host.yaml +++ b/model/resource/host.yaml @@ -106,17 +106,17 @@ groups: examples: [ 'GenuineIntel' ] - id: family requirement_level: opt_in - type: int + type: string brief: > - Numeric value specifying the family or generation of the CPU. - examples: [ 6 ] + Family or generation of the CPU. + examples: [ '6', 'PA-RISC 1.1e' ] - id: model.id requirement_level: opt_in - type: int + type: string brief: > Model identifier. It provides more granular information about the CPU, distinguishing it from other CPUs within the same family. - examples: [ 6 ] + examples: [ '6', '9000/778/B180L' ] - id: model.name requirement_level: opt_in type: string