diff --git a/.chloggen/2047.yaml b/.chloggen/2047.yaml
new file mode 100644
index 0000000000..0ab8b3b452
--- /dev/null
+++ b/.chloggen/2047.yaml
@@ -0,0 +1,10 @@
+change_type: breaking
+component: all
+note: Convert deprecated text to structured format.
+issues: [ 2047 ]
+
+subtext: >
+ This is a breaking change from the schema perspective, but does not change anything for instrumentations
+ or the end users.
+ It breaks compatibility with the (old) [code generation tooling](https://github.com/open-telemetry/build-tools/issues/322).
+ Please use [weaver](https://github.com/open-telemetry/weaver) to generate Semantic Conventions markdown or code.
diff --git a/.vscode/settings.json b/.vscode/settings.json
index 4bf601376d..6bcb1a8ea1 100644
--- a/.vscode/settings.json
+++ b/.vscode/settings.json
@@ -10,7 +10,7 @@
"MD040": false,
},
"yaml.schemas": {
- "https://raw.githubusercontent.com/open-telemetry/weaver/v0.13.2/schemas/semconv.schema.json": [
+ "https://raw.githubusercontent.com/open-telemetry/weaver/v0.15.0/schemas/semconv.schema.json": [
"model/**/*.yaml"
]
},
diff --git a/docs/attributes-registry/android.md b/docs/attributes-registry/android.md
index 2de21274ad..525c411f89 100644
--- a/docs/attributes-registry/android.md
+++ b/docs/attributes-registry/android.md
@@ -33,9 +33,7 @@ This document defines attributes that represents an occurrence of a lifecycle tr
| Attribute | Type | Description | Examples | Stability |
|---|---|---|---|---|
-| `android.state` | string | Deprecated. Use `android.app.state` instead. [2] | `created`; `background`; `foreground` | 
Renamed to `android.app.state` |
-
-**[2] `android.state`:** The Android lifecycle states are defined in [Activity lifecycle callbacks](https://developer.android.com/guide/components/activities/activity-lifecycle#lc), and from which the `OS identifiers` are derived.
+| `android.state` | string | Deprecated. Use `android.app.state` body field instead. | `created`; `background`; `foreground` | 
Use `android.app.state` body field instead. |
---
diff --git a/docs/attributes-registry/code.md b/docs/attributes-registry/code.md
index 952f7ff670..9c8008ce75 100644
--- a/docs/attributes-registry/code.md
+++ b/docs/attributes-registry/code.md
@@ -40,8 +40,8 @@ These deprecated attributes provide context about source code
| Attribute | Type | Description | Examples | Stability |
|---|---|---|---|---|
-| `code.column` | int | Deprecated, use `code.column.number` | `16` | 
Replaced by `code.column.number` |
-| `code.filepath` | string | Deprecated, use `code.file.path` instead | `/usr/local/MyApplication/content_root/app/index.php` | 
Replaced by `code.file.path` |
-| `code.function` | string | Deprecated, use `code.function.name` instead | `serveRequest` | 
Replaced by `code.function.name` |
-| `code.lineno` | int | Deprecated, use `code.line.number` instead | `42` | 
Replaced by `code.line.number` |
+| `code.column` | int | Deprecated, use `code.column.number` | `16` | 
Replaced by `code.column.number`. |
+| `code.filepath` | string | Deprecated, use `code.file.path` instead | `/usr/local/MyApplication/content_root/app/index.php` | 
Replaced by `code.file.path`. |
+| `code.function` | string | Deprecated, use `code.function.name` instead | `serveRequest` | 
Value should be included in `code.function.name` which is expected to be a fully-qualified name. |
+| `code.lineno` | int | Deprecated, use `code.line.number` instead | `42` | 
Replaced by `code.line.number`. |
| `code.namespace` | string | Deprecated, namespace is now included into `code.function.name` | `com.example.MyHttpService` | 
Value should be included in `code.function.name` which is expected to be a fully-qualified name. |
diff --git a/docs/attributes-registry/container.md b/docs/attributes-registry/container.md
index 16b319d8b8..6db90ba994 100644
--- a/docs/attributes-registry/container.md
+++ b/docs/attributes-registry/container.md
@@ -46,7 +46,7 @@ Describes deprecated container attributes.
| Attribute | Type | Description | Examples | Stability |
|---|---|---|---|---|
-| `container.cpu.state` | string | Deprecated, use `cpu.mode` instead. | `user`; `kernel` | 
Replaced by `cpu.mode` |
+| `container.cpu.state` | string | Deprecated, use `cpu.mode` instead. | `user`; `kernel` | 
Replaced by `cpu.mode`. |
| `container.labels.` | string | Deprecated, use `container.label` instead. | `nginx` | 
Replaced by `container.label`. |
---
diff --git a/docs/attributes-registry/db.md b/docs/attributes-registry/db.md
index c3ec072dc0..d754d0d953 100644
--- a/docs/attributes-registry/db.md
+++ b/docs/attributes-registry/db.md
@@ -181,7 +181,7 @@ Describes deprecated database attributes.
| `db.cosmosdb.connection_mode` | string | Deprecated, use `azure.cosmosdb.connection.mode` instead. | `gateway`; `direct` | 
Replaced by `azure.cosmosdb.connection.mode`. |
| `db.cosmosdb.consistency_level` | string | Deprecated, use `cosmosdb.consistency.level` instead. | `Eventual`; `ConsistentPrefix`; `BoundedStaleness`; `Strong`; `Session` | 
Replaced by `azure.cosmosdb.consistency.level`. |
| `db.cosmosdb.container` | string | Deprecated, use `db.collection.name` instead. | `mytable` | 
Replaced by `db.collection.name`. |
-| `db.cosmosdb.operation_type` | string | Deprecated, no replacement at this time. | `batch`; `create`; `delete` | 
No replacement at this time. |
+| `db.cosmosdb.operation_type` | string | Deprecated, no replacement at this time. | `batch`; `create`; `delete` | 
Removed, no replacement at this time. |
| `db.cosmosdb.regions_contacted` | string[] | Deprecated, use `azure.cosmosdb.operation.contacted_regions` instead. | `["North Central US", "Australia East", "Australia Southeast"]` | 
Replaced by `azure.cosmosdb.operation.contacted_regions`. |
| `db.cosmosdb.request_charge` | double | Deprecated, use `azure.cosmosdb.operation.request_charge` instead. | `46.18`; `1.0` | 
Replaced by `azure.cosmosdb.operation.request_charge`. |
| `db.cosmosdb.request_content_length` | int | Deprecated, use `azure.cosmosdb.request.body.size` instead. | | 
Replaced by `azure.cosmosdb.request.body.size`. |
@@ -190,17 +190,17 @@ Describes deprecated database attributes.
| `db.elasticsearch.cluster.name` | string | Deprecated, use `db.namespace` instead. | `e9106fc68e3044f0b1475b04bf4ffd5f` | 
Replaced by `db.namespace`. |
| `db.elasticsearch.node.name` | string | Deprecated, use `elasticsearch.node.name` instead. | `instance-0000000001` | 
Replaced by `elasticsearch.node.name`. |
| `db.elasticsearch.path_parts.` | string | Deprecated, use `db.operation.parameter` instead. | `test-index`; `123` | 
Replaced by `db.operation.parameter`. |
-| `db.instance.id` | string | Deprecated, no general replacement at this time. For Elasticsearch, use `db.elasticsearch.node.name` instead. | `mysql-e26b99z.example.com` | 
Deprecated, no general replacement at this time. For Elasticsearch, use `db.elasticsearch.node.name` instead. |
-| `db.jdbc.driver_classname` | string | Removed, no replacement at this time. | `org.postgresql.Driver`; `com.microsoft.sqlserver.jdbc.SQLServerDriver` | 
Removed as not used. |
+| `db.instance.id` | string | Deprecated, no general replacement at this time. For Elasticsearch, use `db.elasticsearch.node.name` instead. | `mysql-e26b99z.example.com` | 
Removed, no general replacement at this time. For Elasticsearch, use `db.elasticsearch.node.name` instead. |
+| `db.jdbc.driver_classname` | string | Removed, no replacement at this time. | `org.postgresql.Driver`; `com.microsoft.sqlserver.jdbc.SQLServerDriver` | 
Removed, no replacement at this time. |
| `db.mongodb.collection` | string | Deprecated, use `db.collection.name` instead. | `mytable` | 
Replaced by `db.collection.name`. |
-| `db.mssql.instance_name` | string | Deprecated, SQL Server instance is now populated as a part of `db.namespace` attribute. | `MSSQLSERVER` | 
Deprecated, no replacement at this time. |
+| `db.mssql.instance_name` | string | Deprecated, SQL Server instance is now populated as a part of `db.namespace` attribute. | `MSSQLSERVER` | 
Removed, no replacement at this time. |
| `db.name` | string | Deprecated, use `db.namespace` instead. | `customers`; `main` | 
Replaced by `db.namespace`. |
| `db.operation` | string | Deprecated, use `db.operation.name` instead. | `findAndModify`; `HMSET`; `SELECT` | 
Replaced by `db.operation.name`. |
| `db.redis.database_index` | int | Deprecated, use `db.namespace` instead. | `0`; `1`; `15` | 
Replaced by `db.namespace`. |
-| `db.sql.table` | string | Deprecated, use `db.collection.name` instead, but only if not extracting the value from `db.query.text`. | `mytable` | 
Replaced by `db.collection.name`, but only if not extracting the value from `db.query.text`. |
+| `db.sql.table` | string | Deprecated, use `db.collection.name` instead. | `mytable` | 
Replaced by `db.collection.name`, but only if not extracting the value from `db.query.text`. |
| `db.statement` | string | The database statement being executed. | `SELECT * FROM wuser_table`; `SET mykey "WuValue"` | 
Replaced by `db.query.text`. |
| `db.system` | string | Deprecated, use `db.system.name` instead. | `other_sql`; `adabas`; `cache` | 
Replaced by `db.system.name`. |
-| `db.user` | string | Deprecated, no replacement at this time. | `readonly_user`; `reporting_user` | 
No replacement at this time. |
+| `db.user` | string | Deprecated, no replacement at this time. | `readonly_user`; `reporting_user` | 
Removed, no replacement at this time. |
---
diff --git a/docs/attributes-registry/deployment.md b/docs/attributes-registry/deployment.md
index 94e5e04756..4e1769ba88 100644
--- a/docs/attributes-registry/deployment.md
+++ b/docs/attributes-registry/deployment.md
@@ -40,4 +40,4 @@ considered to be identifying the same service:
| Attribute | Type | Description | Examples | Stability |
|---|---|---|---|---|
-| `deployment.environment` | string | 'Deprecated, use `deployment.environment.name` instead.' | `staging`; `production` | 
Deprecated, use `deployment.environment.name` instead. |
+| `deployment.environment` | string | 'Deprecated, use `deployment.environment.name` instead.' | `staging`; `production` | 
Replaced by `deployment.environment.name`. |
diff --git a/docs/attributes-registry/enduser.md b/docs/attributes-registry/enduser.md
index 1f681f4381..9b15b0bd56 100644
--- a/docs/attributes-registry/enduser.md
+++ b/docs/attributes-registry/enduser.md
@@ -31,5 +31,5 @@ Describes deprecated enduser attributes.
| Attribute | Type | Description | Examples | Stability |
|---|---|---|---|---|
-| `enduser.role` | string | Deprecated, use `user.roles` instead. | `admin` | 
Replaced by `user.roles` attribute. |
-| `enduser.scope` | string | Deprecated, no replacement at this time. | `read:message, write:files` | 
Removed. |
+| `enduser.role` | string | Deprecated, use `user.roles` instead. | `admin` | 
Use `user.roles` attribute instead. |
+| `enduser.scope` | string | Deprecated, no replacement at this time. | `read:message, write:files` | 
Removed, no replacement at this time. |
diff --git a/docs/attributes-registry/event.md b/docs/attributes-registry/event.md
index f4f8cc41e4..41eac0c4ee 100644
--- a/docs/attributes-registry/event.md
+++ b/docs/attributes-registry/event.md
@@ -9,4 +9,4 @@ Attributes for Events represented using Log Records.
| Attribute | Type | Description | Examples | Stability |
|---|---|---|---|---|
-| `event.name` | string | Identifies the class / type of event. | `browser.mouse.click`; `device.app.lifecycle` | 
Replaced by EventName top-level field on the LogRecord |
+| `event.name` | string | Identifies the class / type of event. | `browser.mouse.click`; `device.app.lifecycle` | 
Replaced by EventName top-level field on the LogRecord. |
diff --git a/docs/attributes-registry/gen-ai.md b/docs/attributes-registry/gen-ai.md
index b73181cabc..046037647b 100644
--- a/docs/attributes-registry/gen-ai.md
+++ b/docs/attributes-registry/gen-ai.md
@@ -161,8 +161,8 @@ Describes deprecated `gen_ai` attributes.
|---|---|---|---|---|
| `gen_ai.completion` | string | Deprecated, use Event API to report completions contents. | `[{'role': 'assistant', 'content': 'The capital of France is Paris.'}]` | 
Removed, no replacement at this time. |
| `gen_ai.prompt` | string | Deprecated, use Event API to report prompt contents. | `[{'role': 'user', 'content': 'What is the capital of France?'}]` | 
Removed, no replacement at this time. |
-| `gen_ai.usage.completion_tokens` | int | Deprecated, use `gen_ai.usage.output_tokens` instead. | `42` | 
Replaced by `gen_ai.usage.output_tokens` attribute. |
-| `gen_ai.usage.prompt_tokens` | int | Deprecated, use `gen_ai.usage.input_tokens` instead. | `42` | 
Replaced by `gen_ai.usage.input_tokens` attribute. |
+| `gen_ai.usage.completion_tokens` | int | Deprecated, use `gen_ai.usage.output_tokens` instead. | `42` | 
Replaced by `gen_ai.usage.output_tokens`. |
+| `gen_ai.usage.prompt_tokens` | int | Deprecated, use `gen_ai.usage.input_tokens` instead. | `42` | 
Replaced by `gen_ai.usage.input_tokens`. |
## Deprecated OpenAI GenAI Attributes
@@ -171,7 +171,7 @@ Describes deprecated `gen_ai.openai` attributes.
| Attribute | Type | Description | Examples | Stability |
|---|---|---|---|---|
| `gen_ai.openai.request.response_format` | string | Deprecated, use `gen_ai.output.type`. | `text`; `json_object`; `json_schema` | 
Replaced by `gen_ai.output.type`. |
-| `gen_ai.openai.request.seed` | int | Deprecated, use `gen_ai.request.seed`. | `100` | 
Replaced by `gen_ai.request.seed` attribute. |
+| `gen_ai.openai.request.seed` | int | Deprecated, use `gen_ai.request.seed`. | `100` | 
Replaced by `gen_ai.request.seed`. |
---
diff --git a/docs/attributes-registry/http.md b/docs/attributes-registry/http.md
index 5c9e90b3ab..c304663d37 100644
--- a/docs/attributes-registry/http.md
+++ b/docs/attributes-registry/http.md
@@ -114,14 +114,14 @@ Describes deprecated HTTP attributes.
| `http.flavor` | string | Deprecated, use `network.protocol.name` instead. | `1.0`; `1.1`; `2.0` | 
Replaced by `network.protocol.name`. |
| `http.host` | string | Deprecated, use one of `server.address`, `client.address` or `http.request.header.host` instead, depending on the usage. | `www.example.org` | 
Replaced by one of `server.address`, `client.address` or `http.request.header.host`, depending on the usage. |
| `http.method` | string | Deprecated, use `http.request.method` instead. | `GET`; `POST`; `HEAD` | 
Replaced by `http.request.method`. |
-| `http.request_content_length` | int | Deprecated, use `http.request.header.` instead. | `3495` | 
Replaced by `http.request.header.`. |
+| `http.request_content_length` | int | Deprecated, use `http.request.header.content-length` instead. | `3495` | 
Replaced by `http.request.header.content-length`. |
| `http.request_content_length_uncompressed` | int | Deprecated, use `http.request.body.size` instead. | `5493` | 
Replaced by `http.request.body.size`. |
-| `http.response_content_length` | int | Deprecated, use `http.response.header.` instead. | `3495` | 
Replaced by `http.response.header.`. |
-| `http.response_content_length_uncompressed` | int | Deprecated, use `http.response.body.size` instead. | `5493` | 
Replace by `http.response.body.size`. |
-| `http.scheme` | string | Deprecated, use `url.scheme` instead. | `http`; `https` | 
Replaced by `url.scheme` instead. |
+| `http.response_content_length` | int | Deprecated, use `http.response.header.content-length` instead. | `3495` | 
hp.response.header.content-length |
+| `http.response_content_length_uncompressed` | int | Deprecated, use `http.response.body.size` instead. | `5493` | 
Replaced by `http.response.body.size`. |
+| `http.scheme` | string | Deprecated, use `url.scheme` instead. | `http`; `https` | 
Replaced by `url.scheme`. |
| `http.server_name` | string | Deprecated, use `server.address` instead. | `example.com` | 
Replaced by `server.address`. |
| `http.status_code` | int | Deprecated, use `http.response.status_code` instead. | `200` | 
Replaced by `http.response.status_code`. |
-| `http.target` | string | Deprecated, use `url.path` and `url.query` instead. | `/search?q=OpenTelemetry#SemConv` | 
Split to `url.path` and `url.query. |
+| `http.target` | string | Deprecated, use `url.path` and `url.query` instead. | `/search?q=OpenTelemetry#SemConv` | 
Split to `url.path` and `url.query`. |
| `http.url` | string | Deprecated, use `url.full` instead. | `https://www.foo.bar/search?q=OpenTelemetry#SemConv` | 
Replaced by `url.full`. |
| `http.user_agent` | string | Deprecated, use `user_agent.original` instead. | `CERN-LineMode/2.15 libwww/2.17b3`; `Mozilla/5.0 (iPhone; CPU iPhone OS 14_7_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/14.1.2 Mobile/15E148 Safari/604.1` | 
Replaced by `user_agent.original`. |
diff --git a/docs/attributes-registry/ios.md b/docs/attributes-registry/ios.md
index 1b4a7045fc..de513d4885 100644
--- a/docs/attributes-registry/ios.md
+++ b/docs/attributes-registry/ios.md
@@ -34,7 +34,7 @@ The iOS platform on which the iOS application is running.
| Attribute | Type | Description | Examples | Stability |
|---|---|---|---|---|
-| `ios.state` | string | Deprecated. use the `ios.app.state` instead. [2] | `active`; `inactive`; `background` | 
Renamed to `ios.app.state` |
+| `ios.state` | string | [2] | `active`; `inactive`; `background` | 
Replaced by the `ios.app.state` event body field. |
**[2] `ios.state`:** The iOS lifecycle states are defined in the [UIApplicationDelegate documentation](https://developer.apple.com/documentation/uikit/uiapplicationdelegate), and from which the `OS terminology` column values are derived.
diff --git a/docs/attributes-registry/messaging.md b/docs/attributes-registry/messaging.md
index f4580645af..22517be468 100644
--- a/docs/attributes-registry/messaging.md
+++ b/docs/attributes-registry/messaging.md
@@ -189,8 +189,8 @@ Describes deprecated messaging attributes.
| Attribute | Type | Description | Examples | Stability |
|---|---|---|---|---|
| `messaging.client_id` | string | Deprecated, use `messaging.client.id` instead. | `client-5`; `myhost@8742@s8083jm` | 
Replaced by `messaging.client.id`. |
-| `messaging.destination_publish.anonymous` | boolean | Deprecated, no replacement at this time. | | 
No replacement at this time. |
-| `messaging.destination_publish.name` | string | Deprecated, no replacement at this time. | `MyQueue`; `MyTopic` | 
No replacement at this time. |
+| `messaging.destination_publish.anonymous` | boolean | Deprecated, no replacement at this time. | | 
Removed. No replacement at this time. |
+| `messaging.destination_publish.name` | string | Deprecated, no replacement at this time. | `MyQueue`; `MyTopic` | 
Removed. No replacement at this time. |
| `messaging.eventhubs.consumer.group` | string | Deprecated, use `messaging.consumer.group.name` instead. | `$Default` | 
Replaced by `messaging.consumer.group.name`. |
| `messaging.kafka.consumer.group` | string | Deprecated, use `messaging.consumer.group.name` instead. | `my-group` | 
Replaced by `messaging.consumer.group.name`. |
| `messaging.kafka.destination.partition` | int | Deprecated, use `messaging.destination.partition.id` instead. | `2` | 
Replaced by `messaging.destination.partition.id`. |
diff --git a/docs/attributes-registry/network.md b/docs/attributes-registry/network.md
index 8340b1c663..67b2f07101 100644
--- a/docs/attributes-registry/network.md
+++ b/docs/attributes-registry/network.md
@@ -150,7 +150,7 @@ These attributes may be used for any network related operation.
| `net.sock.host.addr` | string | Deprecated, use `network.local.address`. | `/var/my.sock` | 
Replaced by `network.local.address`. |
| `net.sock.host.port` | int | Deprecated, use `network.local.port`. | `8080` | 
Replaced by `network.local.port`. |
| `net.sock.peer.addr` | string | Deprecated, use `network.peer.address`. | `192.168.0.1` | 
Replaced by `network.peer.address`. |
-| `net.sock.peer.name` | string | Deprecated, no replacement at this time. | `/var/my.sock` | 
Removed. |
+| `net.sock.peer.name` | string | Deprecated, no replacement at this time. | `/var/my.sock` | 
Removed. No replacement at this time. |
| `net.sock.peer.port` | int | Deprecated, use `network.peer.port`. | `65531` | 
Replaced by `network.peer.port`. |
| `net.transport` | string | Deprecated, use `network.transport`. | `ip_tcp`; `ip_udp`; `pipe` | 
Replaced by `network.transport`. |
diff --git a/docs/attributes-registry/otel.md b/docs/attributes-registry/otel.md
index dfa36a5362..1cfb9f39bf 100644
--- a/docs/attributes-registry/otel.md
+++ b/docs/attributes-registry/otel.md
@@ -99,5 +99,5 @@ Describes deprecated otel.library attributes.
| Attribute | Type | Description | Examples | Stability |
|---|---|---|---|---|
-| `otel.library.name` | string | Deprecated. Use the `otel.scope.name` attribute | `io.opentelemetry.contrib.mongodb` | 
Use the `otel.scope.name` attribute. |
-| `otel.library.version` | string | Deprecated. Use the `otel.scope.version` attribute. | `1.0.0` | 
Use the `otel.scope.version` attribute. |
+| `otel.library.name` | string | Deprecated. Use the `otel.scope.name` attribute | `io.opentelemetry.contrib.mongodb` | 
Replaced by `otel.scope.name`. |
+| `otel.library.version` | string | Deprecated. Use the `otel.scope.version` attribute. | `1.0.0` | 
Replaced by `otel.scope.version`. |
diff --git a/docs/attributes-registry/process.md b/docs/attributes-registry/process.md
index eb25fd9153..3d5b1ccd51 100644
--- a/docs/attributes-registry/process.md
+++ b/docs/attributes-registry/process.md
@@ -96,8 +96,8 @@ Deprecated process attributes.
| Attribute | Type | Description | Examples | Stability |
|---|---|---|---|---|
-| `process.cpu.state` | string | Deprecated, use `cpu.mode` instead. | `system`; `user`; `wait` | 
Replaced by `cpu.mode` |
-| `process.executable.build_id.profiling` | string | "Deprecated, use `process.executable.build_id.htlhash` instead." | `600DCAFE4A110000F2BF38C493F5FB92` | 
Replaced by `process.executable.build_id.htlhash` |
+| `process.cpu.state` | string | Deprecated, use `cpu.mode` instead. | `system`; `user`; `wait` | 
Replaced by `cpu.mode`. |
+| `process.executable.build_id.profiling` | string | "Deprecated, use `process.executable.build_id.htlhash` instead." | `600DCAFE4A110000F2BF38C493F5FB92` | 
Replaced by `process.executable.build_id.htlhash`. |
---
diff --git a/docs/attributes-registry/system.md b/docs/attributes-registry/system.md
index 3683243ff6..294ae3d91b 100644
--- a/docs/attributes-registry/system.md
+++ b/docs/attributes-registry/system.md
@@ -134,8 +134,8 @@ Deprecated system attributes.
| Attribute | Type | Description | Examples | Stability |
|---|---|---|---|---|
| `system.cpu.logical_number` | int | Deprecated, use `cpu.logical_number` instead. | `1` |  |
-| `system.cpu.state` | string | Deprecated, use `cpu.mode` instead. | `idle`; `interrupt` | 
Replaced by `cpu.mode` |
-| `system.network.state` | string | Deprecated, use `network.connection.state` instead. | `close_wait` | 
Removed, report network connection state with `network.connection.state` attribute |
+| `system.cpu.state` | string | Deprecated, use `cpu.mode` instead. | `idle`; `interrupt` | 
Replaced by `cpu.mode`. |
+| `system.network.state` | string | Deprecated, use `network.connection.state` instead. | `close_wait` | 
Replaced by `network.connection.state`. |
| `system.processes.status` | string | Deprecated, use `system.process.status` instead. | `running` | 
Replaced by `system.process.status`. |
---
diff --git a/docs/attributes-registry/vcs.md b/docs/attributes-registry/vcs.md
index 4adde73c59..4094e4db40 100644
--- a/docs/attributes-registry/vcs.md
+++ b/docs/attributes-registry/vcs.md
@@ -149,11 +149,11 @@ the `.git` extension.
| Attribute | Type | Description | Examples | Stability |
|---|---|---|---|---|
-| `vcs.repository.change.id` | string | Deprecated, use `vcs.change.id` instead. | `123` | 
Deprecated, use `vcs.change.id` instead. |
-| `vcs.repository.change.title` | string | Deprecated, use `vcs.change.title` instead. | `Fixes broken thing`; `feat: add my new feature`; `[chore] update dependency` | 
Deprecated, use `vcs.change.title` instead. |
-| `vcs.repository.ref.name` | string | Deprecated, use `vcs.ref.head.name` instead. | `my-feature-branch`; `tag-1-test` | 
Deprecated, use `vcs.ref.head.name` instead. |
-| `vcs.repository.ref.revision` | string | Deprecated, use `vcs.ref.head.revision` instead. | `9d59409acf479dfa0df1aa568182e43e43df8bbe28d60fcf2bc52e30068802cc`; `main`; `123`; `HEAD` | 
Deprecated, use `vcs.ref.head.revision` instead. |
-| `vcs.repository.ref.type` | string | Deprecated, use `vcs.ref.head.type` instead. | `branch`; `tag` | 
Deprecated, use `vcs.ref.head.type` instead. |
+| `vcs.repository.change.id` | string | Deprecated, use `vcs.change.id` instead. | `123` | 
Replaced by `vcs.change.id`. |
+| `vcs.repository.change.title` | string | Deprecated, use `vcs.change.title` instead. | `Fixes broken thing`; `feat: add my new feature`; `[chore] update dependency` | 
Replaced by `vcs.change.title`. |
+| `vcs.repository.ref.name` | string | Deprecated, use `vcs.ref.head.name` instead. | `my-feature-branch`; `tag-1-test` | 
Replaced by `vcs.ref.head.name`. |
+| `vcs.repository.ref.revision` | string | Deprecated, use `vcs.ref.head.revision` instead. | `9d59409acf479dfa0df1aa568182e43e43df8bbe28d60fcf2bc52e30068802cc`; `main`; `123`; `HEAD` | 
Replaced by `vcs.ref.head.revision`. |
+| `vcs.repository.ref.type` | string | Deprecated, use `vcs.ref.head.type` instead. | `branch`; `tag` | 
Replaced by `vcs.ref.head.type`. |
---
diff --git a/model/android/deprecated/registry-deprecated.yaml b/model/android/deprecated/registry-deprecated.yaml
index 38482b5fed..61f7c6a08c 100644
--- a/model/android/deprecated/registry-deprecated.yaml
+++ b/model/android/deprecated/registry-deprecated.yaml
@@ -7,11 +7,10 @@ groups:
attributes:
- id: android.state
stability: development
- deprecated: "Renamed to `android.app.state`"
- brief: Deprecated. Use `android.app.state` instead.
- note: >
- The Android lifecycle states are defined in [Activity lifecycle callbacks](https://developer.android.com/guide/components/activities/activity-lifecycle#lc),
- and from which the `OS identifiers` are derived.
+ brief: Deprecated. Use `android.app.state` body field instead.
+ deprecated:
+ reason: uncategorized
+ note: Use `android.app.state` body field instead.
type:
members:
- id: created
diff --git a/model/code/registry-deprecated.yaml b/model/code/registry-deprecated.yaml
index de655f8843..fee7f93ed9 100644
--- a/model/code/registry-deprecated.yaml
+++ b/model/code/registry-deprecated.yaml
@@ -8,35 +8,48 @@ groups:
- id: code.function
type: string
stability: development
- deprecated: Replaced by `code.function.name`
+ deprecated:
+ reason: uncategorized
+ note: >
+ Value should be included in `code.function.name` which is expected
+ to be a fully-qualified name.
brief: >
Deprecated, use `code.function.name` instead
examples: serveRequest
- id: code.filepath
type: string
stability: development
- deprecated: Replaced by `code.file.path`
+ deprecated:
+ reason: renamed
+ renamed_to: code.file.path
brief: >
Deprecated, use `code.file.path` instead
examples: /usr/local/MyApplication/content_root/app/index.php
- id: code.lineno
type: int
stability: development
- deprecated: Replaced by `code.line.number`
+ deprecated:
+ reason: renamed
+ renamed_to: code.line.number
brief: >
Deprecated, use `code.line.number` instead
examples: 42
- id: code.column
type: int
stability: development
- deprecated: Replaced by `code.column.number`
+ deprecated:
+ reason: renamed
+ renamed_to: code.column.number
brief: >
Deprecated, use `code.column.number`
examples: 16
- id: code.namespace
type: string
stability: development
- deprecated: Value should be included in `code.function.name` which is expected to be a fully-qualified name.
+ deprecated:
+ reason: uncategorized
+ note: >
+ Value should be included in `code.function.name` which is expected to be a fully-qualified name.
brief: >
Deprecated, namespace is now included into `code.function.name`
examples: com.example.MyHttpService
diff --git a/model/container/deprecated/registry-deprecated.yaml b/model/container/deprecated/registry-deprecated.yaml
index 71f01d40e7..4bf5f230f7 100644
--- a/model/container/deprecated/registry-deprecated.yaml
+++ b/model/container/deprecated/registry-deprecated.yaml
@@ -9,7 +9,9 @@ groups:
examples: [ 'nginx' ]
brief: "Deprecated, use `container.label` instead."
stability: development
- deprecated: "Replaced by `container.label`."
+ deprecated:
+ reason: renamed
+ renamed_to: container.label
- id: container.cpu.state
brief: "Deprecated, use `cpu.mode` instead."
type:
@@ -27,5 +29,7 @@ groups:
brief: "When tasks of the cgroup are in kernel mode (Linux). When all container processes are in kernel mode (Windows)."
stability: development
stability: development
- deprecated: 'Replaced by `cpu.mode`'
+ deprecated:
+ reason: renamed
+ renamed_to: cpu.mode
examples: [ "user", "kernel" ]
diff --git a/model/database/deprecated/metrics-deprecated.yaml b/model/database/deprecated/metrics-deprecated.yaml
index 93273a4c59..6927f40b1b 100644
--- a/model/database/deprecated/metrics-deprecated.yaml
+++ b/model/database/deprecated/metrics-deprecated.yaml
@@ -3,7 +3,9 @@ groups:
type: metric
metric_name: db.client.connections.usage
stability: development
- deprecated: "Replaced by `db.client.connection.count`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.client.connection.count
brief: "Deprecated, use `db.client.connection.count` instead."
instrument: updowncounter
unit: "{connection}"
@@ -17,7 +19,9 @@ groups:
type: metric
metric_name: db.client.connections.idle.max
stability: development
- deprecated: "Replaced by `db.client.connection.idle.max`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.client.connection.idle.max
brief: "Deprecated, use `db.client.connection.idle.max` instead."
instrument: updowncounter
unit: "{connection}"
@@ -29,7 +33,9 @@ groups:
type: metric
metric_name: db.client.connections.idle.min
stability: development
- deprecated: "Replaced by `db.client.connection.idle.min`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.client.connection.idle.min
brief: "Deprecated, use `db.client.connection.idle.min` instead."
instrument: updowncounter
unit: "{connection}"
@@ -41,7 +47,9 @@ groups:
type: metric
metric_name: db.client.connections.max
stability: development
- deprecated: "Replaced by `db.client.connection.max`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.client.connection.max
brief: "Deprecated, use `db.client.connection.max` instead."
instrument: updowncounter
unit: "{connection}"
@@ -53,7 +61,9 @@ groups:
type: metric
metric_name: db.client.connections.pending_requests
stability: development
- deprecated: "Replaced by `db.client.connection.pending_requests`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.client.connection.pending_requests
brief: "Deprecated, use `db.client.connection.pending_requests` instead."
instrument: updowncounter
unit: "{request}"
@@ -65,7 +75,9 @@ groups:
type: metric
metric_name: db.client.connections.timeouts
stability: development
- deprecated: "Replaced by `db.client.connection.timeouts`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.client.connection.timeouts
brief: "Deprecated, use `db.client.connection.timeouts` instead."
instrument: counter
unit: "{timeout}"
@@ -77,7 +89,9 @@ groups:
type: metric
metric_name: db.client.connections.create_time
stability: development
- deprecated: "Replaced by `db.client.connection.create_time`. Note: the unit also changed from `ms` to `s`."
+ deprecated:
+ reason: uncategorized
+ note: Replaced by `db.client.connection.create_time` with unit `s`.
brief: "Deprecated, use `db.client.connection.create_time` instead. Note: the unit also changed from `ms` to `s`."
instrument: histogram
unit: "ms"
@@ -89,7 +103,9 @@ groups:
type: metric
metric_name: db.client.connections.wait_time
stability: development
- deprecated: "Replaced by `db.client.connection.wait_time`. Note: the unit also changed from `ms` to `s`."
+ deprecated:
+ reason: uncategorized
+ note: Replaced by `db.client.connection.wait_time` with unit `s`.
brief: "Deprecated, use `db.client.connection.wait_time` instead. Note: the unit also changed from `ms` to `s`."
instrument: histogram
unit: "ms"
@@ -101,7 +117,9 @@ groups:
type: metric
metric_name: db.client.connections.use_time
stability: development
- deprecated: "Replaced by `db.client.connection.use_time`. Note: the unit also changed from `ms` to `s`."
+ deprecated:
+ reason: uncategorized
+ note: Replaced by `db.client.connection.use_time` with unit `s`.
brief: "Deprecated, use `db.client.connection.use_time` instead. Note: the unit also changed from `ms` to `s`."
instrument: histogram
unit: "ms"
@@ -113,7 +131,9 @@ groups:
type: metric
metric_name: db.client.cosmosdb.operation.request_charge
brief: "Deprecated, use `azure.cosmosdb.client.operation.request_charge` instead."
- deprecated: "Replaced by `azure.cosmosdb.client.operation.request_charge`."
+ deprecated:
+ reason: renamed
+ renamed_to: azure.cosmosdb.client.operation.request_charge
instrument: histogram
unit: "{request_unit}"
stability: development
@@ -146,7 +166,9 @@ groups:
type: metric
metric_name: db.client.cosmosdb.active_instance.count
brief: "Deprecated, use `azure.cosmosdb.client.active_instance.count` instead."
- deprecated: "Replaced by `azure.cosmosdb.client.active_instance.count`."
+ deprecated:
+ reason: renamed
+ renamed_to: azure.cosmosdb.client.active_instance.count
instrument: updowncounter
unit: "{instance}"
stability: development
diff --git a/model/database/deprecated/registry-deprecated.yaml b/model/database/deprecated/registry-deprecated.yaml
index ee1952b2e0..f793a4c03e 100644
--- a/model/database/deprecated/registry-deprecated.yaml
+++ b/model/database/deprecated/registry-deprecated.yaml
@@ -10,91 +10,124 @@ groups:
type: string
brief: 'Deprecated, use `server.address`, `server.port` attributes instead.'
stability: development
- deprecated: "Replaced by `server.address` and `server.port`."
+ deprecated:
+ reason: uncategorized
+ note: >
+ Replaced by `server.address` and `server.port`.
examples: Server=(localdb)\v11.0;Integrated Security=true;
- id: db.jdbc.driver_classname
type: string
brief: 'Removed, no replacement at this time.'
stability: development
- deprecated: 'Removed as not used.'
+ deprecated:
+ reason: obsoleted
+ note: >
+ Removed, no replacement at this time.
examples: ['org.postgresql.Driver', 'com.microsoft.sqlserver.jdbc.SQLServerDriver']
- id: db.operation
type: string
brief: 'Deprecated, use `db.operation.name` instead.'
stability: development
- deprecated: "Replaced by `db.operation.name`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.operation.name
examples: ['findAndModify', 'HMSET', 'SELECT']
- id: db.user
type: string
brief: 'Deprecated, no replacement at this time.'
- deprecated: "No replacement at this time."
+ deprecated:
+ reason: obsoleted
+ note: Removed, no replacement at this time.
stability: development
examples: ['readonly_user', 'reporting_user']
- id: db.statement
type: string
brief: The database statement being executed.
- deprecated: "Replaced by `db.query.text`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.query.text
stability: development
examples: ['SELECT * FROM wuser_table', 'SET mykey "WuValue"']
- id: db.cassandra.table
type: string
stability: development
brief: 'Deprecated, use `db.collection.name` instead.'
- deprecated: "Replaced by `db.collection.name`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.collection.name
examples: 'mytable'
- id: db.cosmosdb.container
type: string
stability: development
brief: 'Deprecated, use `db.collection.name` instead.'
- deprecated: "Replaced by `db.collection.name`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.collection.name
examples: 'mytable'
- id: db.mongodb.collection
type: string
stability: development
brief: 'Deprecated, use `db.collection.name` instead.'
- deprecated: "Replaced by `db.collection.name`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.collection.name
examples: 'mytable'
- id: db.sql.table
type: string
stability: development
- brief: 'Deprecated, use `db.collection.name` instead, but only if not extracting the value from `db.query.text`.'
- deprecated: "Replaced by `db.collection.name`, but only if not extracting the value from `db.query.text`."
+ brief: 'Deprecated, use `db.collection.name` instead.'
+ deprecated:
+ reason: uncategorized
+ note: "Replaced by `db.collection.name`, but only if not extracting the value from `db.query.text`."
examples: 'mytable'
- id: db.redis.database_index
type: int
stability: development
brief: 'Deprecated, use `db.namespace` instead.'
- deprecated: "Replaced by `db.namespace`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.namespace
examples: [0, 1, 15]
- id: db.name
type: string
stability: development
brief: 'Deprecated, use `db.namespace` instead.'
- deprecated: "Replaced by `db.namespace`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.namespace
examples: [ 'customers', 'main' ]
- id: db.mssql.instance_name
type: string
stability: development
brief: 'Deprecated, SQL Server instance is now populated as a part of `db.namespace` attribute.'
- deprecated: 'Deprecated, no replacement at this time.'
+ deprecated:
+ reason: obsoleted
+ note: Removed, no replacement at this time.
examples: 'MSSQLSERVER'
- id: db.instance.id
type: string
stability: development
brief: 'Deprecated, no general replacement at this time. For Elasticsearch, use `db.elasticsearch.node.name` instead.'
- deprecated: 'Deprecated, no general replacement at this time. For Elasticsearch, use `db.elasticsearch.node.name` instead.'
+ deprecated:
+ reason: obsoleted
+ note: >
+ Removed, no general replacement at this time. For Elasticsearch, use `db.elasticsearch.node.name` instead.
examples: 'mysql-e26b99z.example.com'
- id: db.elasticsearch.cluster.name
type: string
stability: development
- deprecated: Replaced by `db.namespace`.
+ deprecated:
+ reason: renamed
+ renamed_to: db.namespace
brief: >
Deprecated, use `db.namespace` instead.
examples: ["e9106fc68e3044f0b1475b04bf4ffd5f"]
- id: db.cosmosdb.status_code
type: int
stability: development
- deprecated: 'Replaced by `db.response.status_code`.'
+ deprecated:
+ reason: renamed
+ renamed_to: db.response.status_code
brief: 'Deprecated, use `db.response.status_code` instead.'
examples: [200, 201]
- id: db.cosmosdb.operation_type
@@ -146,24 +179,33 @@ groups:
value: "upsert"
stability: development
stability: development
- deprecated: "No replacement at this time."
+ deprecated:
+ reason: obsoleted
+ note: >
+ Removed, no replacement at this time.
brief: Deprecated, no replacement at this time.
- id: db.cassandra.coordinator.dc
type: string
stability: development
brief: "Deprecated, use `cassandra.coordinator.dc` instead."
- deprecated: "Replaced by `cassandra.coordinator.dc`."
+ deprecated:
+ reason: renamed
+ renamed_to: cassandra.coordinator.dc
examples: "us-west-2"
- id: db.cassandra.coordinator.id
type: string
stability: development
brief: "Deprecated, use `cassandra.coordinator.id` instead."
- deprecated: "Replaced by `cassandra.coordinator.id`."
+ deprecated:
+ reason: renamed
+ renamed_to: cassandra.coordinator.id
examples: "be13faa2-8574-4d71-926d-27f16cf8a7af"
- id: db.cassandra.consistency_level
brief: "Deprecated, use `cassandra.consistency.level` instead."
- deprecated: "Replaced by `cassandra.consistency.level`."
+ deprecated:
+ reason: renamed
+ renamed_to: cassandra.consistency.level
type:
members:
- id: all
@@ -204,24 +246,32 @@ groups:
type: boolean
stability: development
brief: "Deprecated, use `cassandra.query.idempotent` instead."
- deprecated: "Replaced by `cassandra.query.idempotent`."
+ deprecated:
+ reason: renamed
+ renamed_to: cassandra.query.idempotent
- id: db.cassandra.page_size
type: int
stability: development
brief: "Deprecated, use `cassandra.page.size` instead."
- deprecated: "Replaced by `cassandra.page.size`."
+ deprecated:
+ reason: renamed
+ renamed_to: cassandra.page.size
examples: [5000]
- id: db.cassandra.speculative_execution_count
type: int
stability: development
brief: "Deprecated, use `cassandra.speculative_execution.count` instead."
- deprecated: "Replaced by `cassandra.speculative_execution.count`."
+ deprecated:
+ reason: renamed
+ renamed_to: cassandra.speculative_execution.count
examples: [0, 2]
- id: db.cosmosdb.client_id
type: string
stability: development
brief: "Deprecated, use `azure.client.id` instead."
- deprecated: "Replaced by `azure.client.id`."
+ deprecated:
+ reason: renamed
+ renamed_to: azure.client.id
examples: "3ba4827d-4422-483f-b59f-85b74211c11d"
- id: db.cosmosdb.connection_mode
type:
@@ -236,23 +286,31 @@ groups:
stability: development
stability: development
brief: "Deprecated, use `azure.cosmosdb.connection.mode` instead."
- deprecated: "Replaced by `azure.cosmosdb.connection.mode`."
+ deprecated:
+ reason: renamed
+ renamed_to: azure.cosmosdb.connection.mode
- id: db.cosmosdb.request_charge
type: double
stability: development
brief: "Deprecated, use `azure.cosmosdb.operation.request_charge` instead."
- deprecated: "Replaced by `azure.cosmosdb.operation.request_charge`."
+ deprecated:
+ reason: renamed
+ renamed_to: azure.cosmosdb.operation.request_charge
examples: [46.18, 1.0]
- id: db.cosmosdb.request_content_length
type: int
stability: development
brief: "Deprecated, use `azure.cosmosdb.request.body.size` instead."
- deprecated: "Replaced by `azure.cosmosdb.request.body.size`."
+ deprecated:
+ reason: renamed
+ renamed_to: azure.cosmosdb.request.body.size
- id: db.cosmosdb.sub_status_code
type: int
stability: development
brief: "Deprecated, use `azure.cosmosdb.response.sub_status_code` instead."
- deprecated: "Replaced by `azure.cosmosdb.response.sub_status_code`."
+ deprecated:
+ reason: renamed
+ renamed_to: azure.cosmosdb.response.sub_status_code
examples: [1000, 1002]
- id: db.cosmosdb.consistency_level
type:
@@ -274,13 +332,17 @@ groups:
stability: development
stability: development
brief: "Deprecated, use `cosmosdb.consistency.level` instead."
- deprecated: "Replaced by `azure.cosmosdb.consistency.level`."
+ deprecated:
+ reason: renamed
+ renamed_to: azure.cosmosdb.consistency.level
examples: ["Eventual", "ConsistentPrefix", "BoundedStaleness", "Strong", "Session"]
- id: db.cosmosdb.regions_contacted
type: string[]
stability: development
brief: "Deprecated, use `azure.cosmosdb.operation.contacted_regions` instead."
- deprecated: "Replaced by `azure.cosmosdb.operation.contacted_regions`."
+ deprecated:
+ reason: renamed
+ renamed_to: azure.cosmosdb.operation.contacted_regions
examples:
- ["North Central US", "Australia East", "Australia Southeast"]
- id: db.elasticsearch.node.name
@@ -288,14 +350,18 @@ groups:
stability: development
brief: >
Deprecated, use `elasticsearch.node.name` instead.
- deprecated: "Replaced by `elasticsearch.node.name`."
+ deprecated:
+ reason: renamed
+ renamed_to: elasticsearch.node.name
examples: ["instance-0000000001"]
- id: db.elasticsearch.path_parts
type: template[string]
stability: development
brief: >
Deprecated, use `db.operation.parameter` instead.
- deprecated: "Replaced by `db.operation.parameter`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.operation.parameter
examples:
[
"test-index",
@@ -303,7 +369,9 @@ groups:
]
- id: db.system
brief: "Deprecated, use `db.system.name` instead."
- deprecated: "Replaced by `db.system.name`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.system.name
type:
members:
- id: other_sql
@@ -547,13 +615,17 @@ groups:
value: 'used'
stability: development
brief: "Deprecated, use `db.client.connection.state` instead."
- deprecated: "Replaced by `db.client.connection.state`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.client.connection.state
examples: ["idle"]
- id: pool.name
type: string
stability: development
brief: "Deprecated, use `db.client.connection.pool.name` instead."
- deprecated: "Replaced by `db.client.connection.pool.name`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.client.connection.pool.name
examples: ["myDataSource"]
- id: db.client.connections.state
stability: development
@@ -566,11 +638,15 @@ groups:
value: 'used'
stability: development
brief: "Deprecated, use `db.client.connection.state` instead."
- deprecated: "Replaced by `db.client.connection.state`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.client.connection.state
examples: ["idle"]
- id: db.client.connections.pool.name
type: string
stability: development
brief: "Deprecated, use `db.client.connection.pool.name` instead."
- deprecated: "Replaced by `db.client.connection.pool.name`."
+ deprecated:
+ reason: renamed
+ renamed_to: db.client.connection.pool.name
examples: ["myDataSource"]
diff --git a/model/deployment/deprecated/registry-deprecated.yaml b/model/deployment/deprecated/registry-deprecated.yaml
index e92ab6577e..e200225e96 100644
--- a/model/deployment/deprecated/registry-deprecated.yaml
+++ b/model/deployment/deprecated/registry-deprecated.yaml
@@ -7,7 +7,9 @@ groups:
- id: deployment.environment
type: string
stability: development
- deprecated: 'Deprecated, use `deployment.environment.name` instead.'
+ deprecated:
+ reason: renamed
+ renamed_to: deployment.environment.name
brief: >
'Deprecated, use `deployment.environment.name` instead.'
examples: ['staging', 'production']
diff --git a/model/enduser/deprecated/registry-deprecated.yaml b/model/enduser/deprecated/registry-deprecated.yaml
index 23a7033a86..aec18e4493 100644
--- a/model/enduser/deprecated/registry-deprecated.yaml
+++ b/model/enduser/deprecated/registry-deprecated.yaml
@@ -6,13 +6,17 @@ groups:
attributes:
- id: enduser.role
type: string
- deprecated: "Replaced by `user.roles` attribute."
+ deprecated:
+ reason: uncategorized
+ note: "Use `user.roles` attribute instead."
stability: development
brief: "Deprecated, use `user.roles` instead."
examples: 'admin'
- id: enduser.scope
type: string
- deprecated: "Removed."
+ deprecated:
+ reason: obsoleted
+ note: Removed, no replacement at this time.
stability: development
brief: "Deprecated, no replacement at this time."
examples: 'read:message, write:files'
diff --git a/model/event/deprecated/registry-deprecated.yaml b/model/event/deprecated/registry-deprecated.yaml
index 4370ab953d..701f3ba0a6 100644
--- a/model/event/deprecated/registry-deprecated.yaml
+++ b/model/event/deprecated/registry-deprecated.yaml
@@ -8,7 +8,10 @@ groups:
- id: event.name
type: string
stability: development
- deprecated: "Replaced by EventName top-level field on the LogRecord"
+ deprecated:
+ reason: uncategorized
+ note: >
+ Replaced by EventName top-level field on the LogRecord.
brief: >
Identifies the class / type of event.
examples: ["browser.mouse.click", "device.app.lifecycle"]
diff --git a/model/exceptions/deprecated/registry-deprecated.yaml b/model/exceptions/deprecated/registry-deprecated.yaml
index ed9e57ac93..0bb13c53b4 100644
--- a/model/exceptions/deprecated/registry-deprecated.yaml
+++ b/model/exceptions/deprecated/registry-deprecated.yaml
@@ -8,7 +8,10 @@ groups:
- id: exception.escaped
type: boolean
stability: stable
- deprecated: "It's no longer recommended to record exceptions that are handled
- and do not escape the scope of a span."
+ deprecated:
+ reason: obsoleted
+ note: >
+ It's no longer recommended to record exceptions that are handled
+ and do not escape the scope of a span.
brief: >
Indicates that the exception is escaping the scope of the span.
diff --git a/model/feature-flags/deprecated/registry-deprecated.yaml b/model/feature-flags/deprecated/registry-deprecated.yaml
index e9521db80f..0ea6c7aca0 100644
--- a/model/feature-flags/deprecated/registry-deprecated.yaml
+++ b/model/feature-flags/deprecated/registry-deprecated.yaml
@@ -8,7 +8,9 @@ groups:
type: string
brief: 'Deprecated, use `feature_flag.provider.name` instead.'
stability: development
- deprecated: "Replaced by `feature_flag.provider.name`."
+ deprecated:
+ reason: renamed
+ renamed_to: feature_flag.provider.name
annotations:
code_generation:
exclude: true
@@ -54,17 +56,23 @@ groups:
stability: development
brief: 'Deprecated, use `feature_flag.result.reason` instead.'
stability: development
- deprecated: "Replaced by `feature_flag.result.reason`."
+ deprecated:
+ reason: renamed
+ renamed_to: feature_flag.result.reason
examples: ["static", "targeting_match", "error", "default"]
- id: feature_flag.variant
type: string
brief: 'Deprecated, use `feature_flag.result.variant` instead.'
stability: development
- deprecated: "Replaced by `feature_flag.result.variant`."
+ deprecated:
+ reason: renamed
+ renamed_to: feature_flag.result.variant
examples: ["red", "true", "on"]
- id: feature_flag.evaluation.error.message
type: string
brief: 'Deprecated, use `error.message` instead.'
stability: development
- deprecated: "Replaced by `error.message`."
+ deprecated:
+ reason: renamed
+ renamed_to: error.message
examples: ["Flag `header-color` expected type `string` but found type `number`"]
diff --git a/model/gen-ai/deprecated/registry-deprecated.yaml b/model/gen-ai/deprecated/registry-deprecated.yaml
index fdc80eb89b..27efee6463 100644
--- a/model/gen-ai/deprecated/registry-deprecated.yaml
+++ b/model/gen-ai/deprecated/registry-deprecated.yaml
@@ -7,25 +7,33 @@ groups:
- id: gen_ai.usage.prompt_tokens
type: int
stability: development
- deprecated: Replaced by `gen_ai.usage.input_tokens` attribute.
+ deprecated:
+ reason: renamed
+ renamed_to: gen_ai.usage.input_tokens
brief: "Deprecated, use `gen_ai.usage.input_tokens` instead."
examples: [42]
- id: gen_ai.usage.completion_tokens
type: int
stability: development
- deprecated: Replaced by `gen_ai.usage.output_tokens` attribute.
+ deprecated:
+ reason: renamed
+ renamed_to: gen_ai.usage.output_tokens
brief: "Deprecated, use `gen_ai.usage.output_tokens` instead."
examples: [42]
- id: gen_ai.prompt
type: string
stability: development
- deprecated: "Removed, no replacement at this time."
+ deprecated:
+ reason: obsoleted
+ note: Removed, no replacement at this time.
brief: "Deprecated, use Event API to report prompt contents."
examples: ["[{'role': 'user', 'content': 'What is the capital of France?'}]"]
- id: gen_ai.completion
type: string
stability: development
- deprecated: "Removed, no replacement at this time."
+ deprecated:
+ reason: obsoleted
+ note: Removed, no replacement at this time.
brief: "Deprecated, use Event API to report completions contents."
examples: ["[{'role': 'assistant', 'content': 'The capital of France is Paris.'}]"]
- id: registry.gen_ai.openai.deprecated
@@ -36,7 +44,9 @@ groups:
- id: gen_ai.openai.request.seed
stability: development
type: int
- deprecated: Replaced by `gen_ai.request.seed` attribute.
+ deprecated:
+ reason: renamed
+ renamed_to: gen_ai.request.seed
brief: "Deprecated, use `gen_ai.request.seed`."
examples: [100]
- id: gen_ai.openai.request.response_format
@@ -57,4 +67,6 @@ groups:
stability: development
brief: >
Deprecated, use `gen_ai.output.type`.
- deprecated: "Replaced by `gen_ai.output.type`."
+ deprecated:
+ reason: renamed
+ renamed_to: gen_ai.output.type
diff --git a/model/http/deprecated/registry-deprecated.yaml b/model/http/deprecated/registry-deprecated.yaml
index 1865e663ac..247aab7091 100644
--- a/model/http/deprecated/registry-deprecated.yaml
+++ b/model/http/deprecated/registry-deprecated.yaml
@@ -8,72 +8,97 @@ groups:
type: string
brief: 'Deprecated, use `http.request.method` instead.'
stability: development
- deprecated: "Replaced by `http.request.method`."
+ deprecated:
+ reason: renamed
+ renamed_to: http.request.method
examples: ["GET", "POST", "HEAD"]
- id: http.status_code
type: int
brief: 'Deprecated, use `http.response.status_code` instead.'
stability: development
- deprecated: "Replaced by `http.response.status_code`."
+ deprecated:
+ reason: renamed
+ renamed_to: http.response.status_code
examples: [200]
- id: http.scheme
type: string
brief: 'Deprecated, use `url.scheme` instead.'
stability: development
- deprecated: "Replaced by `url.scheme` instead."
+ deprecated:
+ reason: renamed
+ renamed_to: url.scheme
examples: ['http', 'https']
- id: http.url
type: string
brief: 'Deprecated, use `url.full` instead.'
stability: development
- deprecated: "Replaced by `url.full`."
+ deprecated:
+ reason: renamed
+ renamed_to: url.full
examples: ['https://www.foo.bar/search?q=OpenTelemetry#SemConv']
- id: http.target
type: string
brief: 'Deprecated, use `url.path` and `url.query` instead.'
stability: development
- deprecated: "Split to `url.path` and `url.query."
+ deprecated:
+ reason: obsoleted
+ note: Split to `url.path` and `url.query`.
examples: ['/search?q=OpenTelemetry#SemConv']
- id: http.request_content_length
type: int
- brief: 'Deprecated, use `http.request.header.` instead.'
+ brief: 'Deprecated, use `http.request.header.content-length` instead.'
stability: development
- deprecated: "Replaced by `http.request.header.`."
+ deprecated:
+ reason: uncategorized
+ note: Replaced by `http.request.header.content-length`.
examples: 3495
- id: http.response_content_length
type: int
- brief: 'Deprecated, use `http.response.header.` instead.'
+ brief: 'Deprecated, use `http.response.header.content-length` instead.'
stability: development
- deprecated: "Replaced by `http.response.header.`."
+ deprecated:
+ reason: uncategorized
+ note: hp.response.header.content-length
examples: 3495
- id: http.client_ip
type: string
stability: development
- deprecated: "Replaced by `client.address`."
+ deprecated:
+ reason: renamed
+ renamed_to: client.address
brief: "Deprecated, use `client.address` instead."
examples: '83.164.160.102'
- id: http.host
type: string
stability: development
- deprecated: "Replaced by one of `server.address`, `client.address` or `http.request.header.host`, depending on the usage."
+ deprecated:
+ reason: uncategorized
+ note: >
+ Replaced by one of `server.address`, `client.address` or `http.request.header.host`, depending on the usage.
brief: "Deprecated, use one of `server.address`, `client.address` or `http.request.header.host` instead, depending on the usage."
examples: ['www.example.org']
- id: http.request_content_length_uncompressed
stability: development
- deprecated: "Replaced by `http.request.body.size`."
+ deprecated:
+ reason: renamed
+ renamed_to: http.request.body.size
type: int
brief: "Deprecated, use `http.request.body.size` instead."
examples: 5493
- id: http.response_content_length_uncompressed
stability: development
- deprecated: "Replace by `http.response.body.size`."
+ deprecated:
+ reason: renamed
+ renamed_to: http.response.body.size
type: int
brief: "Deprecated, use `http.response.body.size` instead."
examples: 5493
- id: http.server_name
type: string
stability: development
- deprecated: "Replaced by `server.address`."
+ deprecated:
+ reason: renamed
+ renamed_to: server.address
brief: "Deprecated, use `server.address` instead."
examples: ['example.com']
- id: http.flavor
@@ -104,12 +129,16 @@ groups:
brief: 'QUIC protocol.'
stability: development
brief: 'Deprecated, use `network.protocol.name` instead.'
- deprecated: "Replaced by `network.protocol.name`."
+ deprecated:
+ reason: renamed
+ renamed_to: network.protocol.name
stability: development
- id: http.user_agent
type: string
brief: 'Deprecated, use `user_agent.original` instead.'
examples: ['CERN-LineMode/2.15 libwww/2.17b3',
'Mozilla/5.0 (iPhone; CPU iPhone OS 14_7_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/14.1.2 Mobile/15E148 Safari/604.1']
- deprecated: "Replaced by `user_agent.original`."
+ deprecated:
+ reason: renamed
+ renamed_to: user_agent.original
stability: development
diff --git a/model/ios/deprecated/registry-deprecated.yaml b/model/ios/deprecated/registry-deprecated.yaml
index af68408617..f3dc1bd0e6 100644
--- a/model/ios/deprecated/registry-deprecated.yaml
+++ b/model/ios/deprecated/registry-deprecated.yaml
@@ -7,8 +7,10 @@ groups:
attributes:
- id: ios.state
stability: development
- deprecated: "Renamed to `ios.app.state`"
- brief: Deprecated. use the `ios.app.state` instead.
+ deprecated:
+ reason: uncategorized
+ note:
+ Replaced by the `ios.app.state` event body field.
note: >
The iOS lifecycle states are defined in the [UIApplicationDelegate documentation](https://developer.apple.com/documentation/uikit/uiapplicationdelegate),
and from which the `OS terminology` column values are derived.
diff --git a/model/jvm/deprecated/metrics-deprecated.yaml b/model/jvm/deprecated/metrics-deprecated.yaml
index bc0867981d..e188d6917b 100644
--- a/model/jvm/deprecated/metrics-deprecated.yaml
+++ b/model/jvm/deprecated/metrics-deprecated.yaml
@@ -3,7 +3,9 @@ groups:
type: metric
metric_name: jvm.buffer.memory.usage
stability: development
- deprecated: "Replaced by `jvm.buffer.memory.used`."
+ deprecated:
+ reason: renamed
+ renamed_to: jvm.buffer.memory.used
brief: "Deprecated, use `jvm.buffer.memory.used` instead."
extends: attributes.jvm.buffer
instrument: updowncounter
diff --git a/model/k8s/deprecated/metrics-deprecated.yaml b/model/k8s/deprecated/metrics-deprecated.yaml
index 7d43f7c801..13da0fdfd1 100644
--- a/model/k8s/deprecated/metrics-deprecated.yaml
+++ b/model/k8s/deprecated/metrics-deprecated.yaml
@@ -3,27 +3,19 @@ groups:
type: metric
metric_name: k8s.replication_controller.desired_pods
stability: development
- deprecated: "Replaced by `k8s.replicationcontroller.desired_pods`."
+ deprecated:
+ reason: renamed
+ renamed_to: k8s.replicationcontroller.desired_pods
brief: "Deprecated, use `k8s.replicationcontroller.desired_pods` instead."
- note: |
- This metric aligns with the `replicas` field of the
- [K8s ReplicationControllerSpec](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.30/#replicationcontrollerspec-v1-core)
-
- This metric SHOULD, at a minimum, be reported against a
- [`k8s.replicationcontroller`](../resource/k8s.md#replicationcontroller) resource.
instrument: updowncounter
unit: "{pod}"
- id: metric.k8s.replication_controller.available_pods
type: metric
metric_name: k8s.replication_controller.available_pods
stability: development
- deprecated: "Replaced by `k8s.replicationcontroller.available_pods`."
+ deprecated:
+ reason: renamed
+ renamed_to: k8s.replicationcontroller.available_pods
brief: "Deprecated, use `k8s.replicationcontroller.available_pods` instead."
- note: |
- This metric aligns with the `availableReplicas` field of the
- [K8s ReplicationControllerStatus](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.30/#replicationcontrollerstatus-v1-core)
-
- This metric SHOULD, at a minimum, be reported against a
- [`k8s.replicationcontroller`](../resource/k8s.md#replicationcontroller) resource.
instrument: updowncounter
unit: "{pod}"
diff --git a/model/k8s/deprecated/registry-deprecated.yaml b/model/k8s/deprecated/registry-deprecated.yaml
index b053eb9734..40518a54d8 100644
--- a/model/k8s/deprecated/registry-deprecated.yaml
+++ b/model/k8s/deprecated/registry-deprecated.yaml
@@ -9,4 +9,6 @@ groups:
examples: ['my-app']
brief: "Deprecated, use `k8s.pod.label` instead."
stability: development
- deprecated: "Replaced by `k8s.pod.label`."
+ deprecated:
+ reason: renamed
+ renamed_to: k8s.pod.label
diff --git a/model/messaging/deprecated/metrics-deprecated.yaml b/model/messaging/deprecated/metrics-deprecated.yaml
index 4b083c42b6..7d9d125ca1 100644
--- a/model/messaging/deprecated/metrics-deprecated.yaml
+++ b/model/messaging/deprecated/metrics-deprecated.yaml
@@ -3,7 +3,9 @@ groups:
type: metric
metric_name: messaging.publish.duration
brief: "Deprecated. Use `messaging.client.operation.duration` instead."
- deprecated: "Replaced by `messaging.client.operation.duration`."
+ deprecated:
+ reason: renamed
+ renamed_to: messaging.client.operation.duration
stability: development
instrument: histogram
unit: "s"
@@ -13,7 +15,9 @@ groups:
type: metric
metric_name: messaging.receive.duration
brief: "Deprecated. Use `messaging.client.operation.duration` instead."
- deprecated: "Replaced by `messaging.client.operation.duration`."
+ deprecated:
+ reason: renamed
+ renamed_to: messaging.client.operation.duration
stability: development
instrument: histogram
unit: "s"
@@ -23,7 +27,9 @@ groups:
type: metric
metric_name: messaging.process.messages
brief: "Deprecated. Use `messaging.client.consumed.messages` instead."
- deprecated: "Replaced by `messaging.client.consumed.messages`."
+ deprecated:
+ reason: renamed
+ renamed_to: messaging.client.consumed.messages
stability: development
instrument: counter
unit: "{message}"
@@ -32,8 +38,10 @@ groups:
- id: metric.messaging.publish.messages
type: metric
metric_name: messaging.publish.messages
- brief: "Deprecated. Use `messaging.client.produced.messages` instead."
- deprecated: "Replaced by `messaging.client.produced.messages`."
+ brief: "Deprecated. Use `messaging.client.sent.messages` instead."
+ deprecated:
+ reason: renamed
+ renamed_to: messaging.client.sent.messages
stability: development
instrument: counter
unit: "{message}"
@@ -43,7 +51,9 @@ groups:
type: metric
metric_name: messaging.receive.messages
brief: "Deprecated. Use `messaging.client.consumed.messages` instead."
- deprecated: "Replaced by `messaging.client.consumed.messages`."
+ deprecated:
+ reason: renamed
+ renamed_to: messaging.client.consumed.messages
stability: development
instrument: counter
unit: "{message}"
@@ -53,7 +63,9 @@ groups:
type: metric
metric_name: messaging.client.published.messages
brief: "Deprecated. Use `messaging.client.sent.messages` instead."
- deprecated: "Replaced by `messaging.client.sent.messages`."
+ deprecated:
+ reason: renamed
+ renamed_to: messaging.client.sent.messages
stability: development
instrument: counter
unit: "{message}"
diff --git a/model/messaging/deprecated/registry-deprecated.yaml b/model/messaging/deprecated/registry-deprecated.yaml
index ad0414d02c..72cb669384 100644
--- a/model/messaging/deprecated/registry-deprecated.yaml
+++ b/model/messaging/deprecated/registry-deprecated.yaml
@@ -10,7 +10,9 @@ groups:
brief: >
Deprecated, use `messaging.destination.partition.id` instead.
examples: 2
- deprecated: "Replaced by `messaging.destination.partition.id`."
+ deprecated:
+ reason: renamed
+ renamed_to: messaging.destination.partition.id
stability: development
- id: messaging.operation
type: string
@@ -18,14 +20,18 @@ groups:
brief: >
Deprecated, use `messaging.operation.type` instead.
examples: ["publish", "create", "process"]
- deprecated: "Replaced by `messaging.operation.type`."
+ deprecated:
+ reason: renamed
+ renamed_to: messaging.operation.type
- id: messaging.client_id
type: string
stability: development
brief: >
Deprecated, use `messaging.client.id` instead.
examples: ['client-5', 'myhost@8742@s8083jm']
- deprecated: "Replaced by `messaging.client.id`."
+ deprecated:
+ reason: renamed
+ renamed_to: messaging.client.id
annotations:
code_generation:
exclude: true
@@ -33,7 +39,9 @@ groups:
type: string
brief: >
Deprecated, use `messaging.consumer.group.name` instead.
- deprecated: "Replaced by `messaging.consumer.group.name`."
+ deprecated:
+ reason: renamed
+ renamed_to: messaging.consumer.group.name
stability: development
examples: 'my-group'
- id: messaging.rocketmq.client_group
@@ -42,36 +50,49 @@ groups:
Deprecated, use `messaging.consumer.group.name` instead.
stability: development
examples: 'myConsumerGroup'
- deprecated: "Replaced by `messaging.consumer.group.name` on the consumer spans. No replacement for producer spans."
+ deprecated:
+ reason: uncategorized
+ note: >
+ Replaced by `messaging.consumer.group.name` on the consumer spans. No replacement for producer spans.
- id: messaging.eventhubs.consumer.group
type: string
brief: >
Deprecated, use `messaging.consumer.group.name` instead.
stability: development
examples: '$Default'
- deprecated: "Replaced by `messaging.consumer.group.name`."
+ deprecated:
+ reason: renamed
+ renamed_to: messaging.consumer.group.name
- id: messaging.servicebus.destination.subscription_name
type: string
brief: >
Deprecated, use `messaging.destination.subscription.name` instead.
stability: development
examples: 'subscription-a'
- deprecated: "Replaced by `messaging.destination.subscription.name`."
+ deprecated:
+ reason: renamed
+ renamed_to: messaging.destination.subscription.name
- id: messaging.kafka.message.offset
type: int
stability: development
brief: >
Deprecated, use `messaging.kafka.offset` instead.
examples: 42
- deprecated: "Replaced by `messaging.kafka.offset`."
+ deprecated:
+ reason: renamed
+ renamed_to: messaging.kafka.offset
- id: messaging.destination_publish.anonymous
type: boolean
stability: development
brief: 'Deprecated, no replacement at this time.'
- deprecated: "No replacement at this time."
+ deprecated:
+ reason: obsoleted
+ note: "Removed. No replacement at this time."
- id: messaging.destination_publish.name
type: string
stability: development
brief: 'Deprecated, no replacement at this time.'
- deprecated: "No replacement at this time."
+ deprecated:
+ reason: obsoleted
+ note: "Removed. No replacement at this time."
examples: ['MyQueue', 'MyTopic']
diff --git a/model/network/deprecated/registry-deprecated.yaml b/model/network/deprecated/registry-deprecated.yaml
index 1e5512cc9f..408e76667a 100644
--- a/model/network/deprecated/registry-deprecated.yaml
+++ b/model/network/deprecated/registry-deprecated.yaml
@@ -7,67 +7,89 @@ groups:
attributes:
- id: net.sock.peer.name
type: string
- deprecated: "Removed."
+ deprecated:
+ reason: obsoleted
+ note: "Removed. No replacement at this time."
stability: development
brief: Deprecated, no replacement at this time.
examples: ['/var/my.sock']
- id: net.sock.peer.addr
type: string
- deprecated: "Replaced by `network.peer.address`."
+ deprecated:
+ reason: renamed
+ renamed_to: network.peer.address
stability: development
brief: Deprecated, use `network.peer.address`.
examples: ['192.168.0.1']
- id: net.sock.peer.port
type: int
- deprecated: "Replaced by `network.peer.port`."
+ deprecated:
+ reason: renamed
+ renamed_to: network.peer.port
stability: development
examples: [65531]
brief: Deprecated, use `network.peer.port`.
- id: net.peer.name
type: string
- deprecated: "Replaced by `server.address` on client spans and `client.address` on server spans."
+ deprecated:
+ reason: uncategorized
+ note: Replaced by `server.address` on client spans and `client.address` on server spans.
stability: development
brief: Deprecated, use `server.address` on client spans and `client.address` on server spans.
examples: ['example.com']
- id: net.peer.port
type: int
- deprecated: "Replaced by `server.port` on client spans and `client.port` on server spans."
+ deprecated:
+ reason: uncategorized
+ note: Replaced by `server.port` on client spans and `client.port` on server spans.
stability: development
brief: Deprecated, use `server.port` on client spans and `client.port` on server spans.
examples: [8080]
- id: net.peer.ip
type: string
- deprecated: "Replaced by `network.peer.address`."
+ deprecated:
+ reason: renamed
+ renamed_to: network.peer.address
stability: development
brief: Deprecated, use `network.peer.address`.
examples: '127.0.0.1'
- id: net.host.name
type: string
- deprecated: "Replaced by `server.address`."
+ deprecated:
+ reason: renamed
+ renamed_to: server.address
stability: development
brief: Deprecated, use `server.address`.
examples: ['example.com']
- id: net.host.ip
type: string
- deprecated: "Replaced by `network.local.address`."
+ deprecated:
+ reason: renamed
+ renamed_to: network.local.address
stability: development
brief: Deprecated, use `network.local.address`.
examples: '192.168.0.1'
- id: net.host.port
type: int
- deprecated: "Replaced by `server.port`."
+ deprecated:
+ reason: renamed
+ renamed_to: server.port
stability: development
brief: Deprecated, use `server.port`.
examples: [8080]
- id: net.sock.host.addr
type: string
- deprecated: "Replaced by `network.local.address`."
+ deprecated:
+ reason: renamed
+ renamed_to: network.local.address
stability: development
brief: Deprecated, use `network.local.address`.
examples: ['/var/my.sock']
- id: net.sock.host.port
type: int
- deprecated: "Replaced by `network.local.port`."
+ deprecated:
+ reason: renamed
+ renamed_to: network.local.port
stability: development
brief: Deprecated, use `network.local.port`.
examples: [8080]
@@ -96,18 +118,24 @@ groups:
value: "other"
stability: development
brief: 'Something else (non IP-based).'
- deprecated: "Replaced by `network.transport`."
+ deprecated:
+ reason: renamed
+ renamed_to: network.transport
stability: development
brief: Deprecated, use `network.transport`.
- id: net.protocol.name
type: string
- deprecated: "Replaced by `network.protocol.name`."
+ deprecated:
+ reason: renamed
+ renamed_to: network.protocol.name
stability: development
brief: Deprecated, use `network.protocol.name`.
examples: ['amqp', 'http', 'mqtt']
- id: net.protocol.version
type: string
- deprecated: "Replaced by `network.protocol.version`."
+ deprecated:
+ reason: renamed
+ renamed_to: network.protocol.version
stability: development
brief: Deprecated, use `network.protocol.version`.
examples: '3.1.1'
@@ -126,6 +154,8 @@ groups:
value: 'unix'
brief: "Unix domain socket path"
stability: development
- deprecated: "Split to `network.transport` and `network.type`."
+ deprecated:
+ reason: uncategorized
+ note: Split to `network.transport` and `network.type`.
stability: development
brief: Deprecated, use `network.transport` and `network.type`.
diff --git a/model/otel/deprecated/metrics-deprecated.yaml b/model/otel/deprecated/metrics-deprecated.yaml
index 9b214ab7bc..4c547e605f 100644
--- a/model/otel/deprecated/metrics-deprecated.yaml
+++ b/model/otel/deprecated/metrics-deprecated.yaml
@@ -3,7 +3,9 @@ groups:
type: metric
metric_name: otel.sdk.span.live.count
stability: development
- deprecated: "Renamed to `otel.sdk.span.live`."
+ deprecated:
+ reason: renamed
+ renamed_to: otel.sdk.span.live
brief: "Deprecated, use `otel.sdk.span.live` instead."
instrument: updowncounter
unit: "{span}"
@@ -11,7 +13,9 @@ groups:
type: metric
metric_name: otel.sdk.span.ended.count
stability: development
- deprecated: "Renamed to `otel.sdk.span.ended`."
+ deprecated:
+ reason: renamed
+ renamed_to: otel.sdk.span.ended
brief: "Deprecated, use `otel.sdk.span.ended` instead."
instrument: counter
unit: "{span}"
@@ -19,7 +23,9 @@ groups:
type: metric
metric_name: otel.sdk.processor.span.processed.count
stability: development
- deprecated: "Renamed to `otel.sdk.processor.span.processed`."
+ deprecated:
+ reason: renamed
+ renamed_to: otel.sdk.processor.span.processed
brief: "Deprecated, use `otel.sdk.processor.span.processed` instead."
instrument: updowncounter
unit: "{span}"
@@ -27,7 +33,9 @@ groups:
type: metric
metric_name: otel.sdk.exporter.span.inflight.count
stability: development
- deprecated: "Renamed to `otel.sdk.exporter.span.inflight`."
+ deprecated:
+ reason: renamed
+ renamed_to: otel.sdk.exporter.span.inflight
brief: "Deprecated, use `otel.sdk.exporter.span.inflight` instead."
instrument: updowncounter
unit: "{span}"
@@ -35,7 +43,9 @@ groups:
type: metric
metric_name: otel.sdk.exporter.span.exported.count
stability: development
- deprecated: "Renamed to `otel.sdk.exporter.span.exported`."
+ deprecated:
+ reason: renamed
+ renamed_to: otel.sdk.exporter.span.exported
brief: "Deprecated, use `otel.sdk.exporter.span.exported` instead."
instrument: updowncounter
unit: "{span}"
diff --git a/model/otel/deprecated/registry-deprecated.yaml b/model/otel/deprecated/registry-deprecated.yaml
index 676a943a11..21c27d889d 100644
--- a/model/otel/deprecated/registry-deprecated.yaml
+++ b/model/otel/deprecated/registry-deprecated.yaml
@@ -6,13 +6,17 @@ groups:
attributes:
- id: otel.library.name
type: string
- deprecated: "Use the `otel.scope.name` attribute."
+ deprecated:
+ reason: renamed
+ renamed_to: otel.scope.name
stability: development
brief: "Deprecated. Use the `otel.scope.name` attribute"
examples: ['io.opentelemetry.contrib.mongodb']
- id: otel.library.version
type: string
- deprecated: "Use the `otel.scope.version` attribute."
+ deprecated:
+ reason: renamed
+ renamed_to: otel.scope.version
stability: development
brief: "Deprecated. Use the `otel.scope.version` attribute."
examples: ['1.0.0']
diff --git a/model/process/deprecated/registry-deprecated.yaml b/model/process/deprecated/registry-deprecated.yaml
index 199556530d..31511381fb 100644
--- a/model/process/deprecated/registry-deprecated.yaml
+++ b/model/process/deprecated/registry-deprecated.yaml
@@ -6,7 +6,9 @@ groups:
attributes:
- id: process.cpu.state
brief: "Deprecated, use `cpu.mode` instead."
- deprecated: 'Replaced by `cpu.mode`'
+ deprecated:
+ reason: renamed
+ renamed_to: cpu.mode
type:
members:
- id: system
@@ -22,7 +24,9 @@ groups:
- id: process.executable.build_id.profiling
stability: development
type: string
- deprecated: 'Replaced by `process.executable.build_id.htlhash`'
+ deprecated:
+ reason: renamed
+ renamed_to: process.executable.build_id.htlhash
brief: >
"Deprecated, use `process.executable.build_id.htlhash` instead."
examples: ['600DCAFE4A110000F2BF38C493F5FB92']
diff --git a/model/rpc/deprecated/registry-deprecated.yaml b/model/rpc/deprecated/registry-deprecated.yaml
index 7319802197..5eb2f01235 100644
--- a/model/rpc/deprecated/registry-deprecated.yaml
+++ b/model/rpc/deprecated/registry-deprecated.yaml
@@ -15,19 +15,27 @@ groups:
stability: development
stability: development
brief: "Deprecated, use `rpc.message.type` instead."
- deprecated: "Replaced by `rpc.message.type`."
+ deprecated:
+ reason: renamed
+ renamed_to: rpc.message.type
- id: message.id
type: int
stability: development
brief: "Deprecated, use `rpc.message.id` instead."
- deprecated: "Replaced by `rpc.message.id`."
+ deprecated:
+ reason: renamed
+ renamed_to: rpc.message.id
- id: message.compressed_size
type: int
stability: development
brief: "Deprecated, use `rpc.message.compressed_size` instead."
- deprecated: "Replaced by `rpc.message.compressed_size`."
+ deprecated:
+ reason: renamed
+ renamed_to: rpc.message.compressed_size
- id: message.uncompressed_size
type: int
stability: development
brief: "Deprecated, use `rpc.message.uncompressed_size` instead."
- deprecated: "Replaced by `rpc.message.uncompressed_size`."
+ deprecated:
+ reason: renamed
+ renamed_to: rpc.message.uncompressed_size
diff --git a/model/system/deprecated/metrics-deprecated.yaml b/model/system/deprecated/metrics-deprecated.yaml
index 7b36ba7582..969b0d8bd1 100644
--- a/model/system/deprecated/metrics-deprecated.yaml
+++ b/model/system/deprecated/metrics-deprecated.yaml
@@ -3,7 +3,9 @@ groups:
type: metric
metric_name: system.cpu.time
brief: "Deprecated. Use `cpu.time` instead."
- deprecated: "Replaced by `cpu.time`."
+ deprecated:
+ reason: renamed
+ renamed_to: cpu.time
stability: development
instrument: counter
unit: "s"
@@ -12,7 +14,9 @@ groups:
type: metric
metric_name: system.cpu.utilization
brief: "Deprecated. Use `cpu.utilization` instead."
- deprecated: "Replaced by `cpu.utilization`."
+ deprecated:
+ reason: renamed
+ renamed_to: cpu.utilization
stability: development
instrument: gauge
unit: "1"
@@ -21,7 +25,9 @@ groups:
type: metric
metric_name: system.cpu.frequency
brief: "Deprecated. Use `cpu.frequency` instead."
- deprecated: "Replaced by `cpu.frequency`."
+ deprecated:
+ reason: renamed
+ renamed_to: cpu.frequency
stability: development
instrument: gauge
unit: "{Hz}"
diff --git a/model/system/deprecated/registry-deprecated.yaml b/model/system/deprecated/registry-deprecated.yaml
index 633d0a65b5..af5c79e0df 100644
--- a/model/system/deprecated/registry-deprecated.yaml
+++ b/model/system/deprecated/registry-deprecated.yaml
@@ -20,7 +20,9 @@ groups:
value: 'defunct'
stability: development
brief: "Deprecated, use `system.process.status` instead."
- deprecated: "Replaced by `system.process.status`."
+ deprecated:
+ reason: renamed
+ renamed_to: system.process.status
stability: development
examples: ["running"]
- id: system.cpu.state
@@ -49,10 +51,14 @@ groups:
stability: development
brief: "Deprecated, use `cpu.mode` instead."
stability: development
- deprecated: 'Replaced by `cpu.mode`'
+ deprecated:
+ reason: renamed
+ renamed_to: cpu.mode
examples: [ "idle", "interrupt" ]
- id: system.network.state
- deprecated: 'Removed, report network connection state with `network.connection.state` attribute'
+ deprecated:
+ reason: renamed
+ renamed_to: network.connection.state
type:
members:
- id: close
diff --git a/model/tls/deprecated/registry-deprecated.yaml b/model/tls/deprecated/registry-deprecated.yaml
index a9116e57c9..7e3dd101c7 100644
--- a/model/tls/deprecated/registry-deprecated.yaml
+++ b/model/tls/deprecated/registry-deprecated.yaml
@@ -6,6 +6,8 @@ groups:
- id: tls.client.server_name
type: string
stability: development
- deprecated: "Replaced by `server.address`."
+ deprecated:
+ reason: renamed
+ renamed_to: server.address
brief: "Deprecated, use `server.address` instead."
examples: ["opentelemetry.io"]
diff --git a/model/vcs/deprecated/registry-deprecated.yaml b/model/vcs/deprecated/registry-deprecated.yaml
index 34d031fce0..8243020733 100644
--- a/model/vcs/deprecated/registry-deprecated.yaml
+++ b/model/vcs/deprecated/registry-deprecated.yaml
@@ -7,7 +7,9 @@ groups:
- id: vcs.repository.ref.name
type: string
stability: development
- deprecated: 'Deprecated, use `vcs.ref.head.name` instead.'
+ deprecated:
+ reason: renamed
+ renamed_to: vcs.ref.head.name
brief: >
Deprecated, use `vcs.ref.head.name` instead.
examples: ["my-feature-branch", "tag-1-test"]
@@ -23,14 +25,18 @@ groups:
brief: "[tag](https://git-scm.com/docs/gitglossary#Documentation/gitglossary.txt-aiddeftagatag)"
stability: development
stability: development
- deprecated: 'Deprecated, use `vcs.ref.head.type` instead.'
+ deprecated:
+ reason: renamed
+ renamed_to: vcs.ref.head.type
brief: >
Deprecated, use `vcs.ref.head.type` instead.
examples: ["branch", "tag"]
- id: vcs.repository.ref.revision
type: string
stability: development
- deprecated: 'Deprecated, use `vcs.ref.head.revision` instead.'
+ deprecated:
+ reason: renamed
+ renamed_to: vcs.ref.head.revision
brief: >
Deprecated, use `vcs.ref.head.revision` instead.
examples:
@@ -43,7 +49,9 @@ groups:
- id: vcs.repository.change.title
type: string
stability: development
- deprecated: 'Deprecated, use `vcs.change.title` instead.'
+ deprecated:
+ reason: renamed
+ renamed_to: vcs.change.title
brief: >
Deprecated, use `vcs.change.title` instead.
examples:
@@ -55,7 +63,9 @@ groups:
- id: vcs.repository.change.id
type: string
stability: development
- deprecated: 'Deprecated, use `vcs.change.id` instead.'
+ deprecated:
+ reason: renamed
+ renamed_to: vcs.change.id
brief: >
Deprecated, use `vcs.change.id` instead.
examples: ["123"]
diff --git a/policies/deprecation.rego b/policies/deprecation.rego
new file mode 100644
index 0000000000..ade1b69147
--- /dev/null
+++ b/policies/deprecation.rego
@@ -0,0 +1,64 @@
+package after_resolution
+
+import rego.v1
+
+registry_attribute_names := {attr.name |
+ some g in input.groups
+ some attr in g.attributes
+ not attr.deprecated
+}
+
+registry_metric_names := {group.metric_name |
+ some group in input.groups
+ group.type == "metric"
+ not group.deprecated
+}
+
+registry_event_names := {group.name |
+ some group in input.groups
+ group.type == "event"
+ not group.deprecated
+}
+
+# attribute.deprecated.renamed_to must be another attribute
+deny contains deprecation_violation(description, group.id, "") if {
+ group := input.groups[_]
+ attr := group.attributes[_]
+ attr.deprecated != null
+ attr.deprecated.renamed_to != null
+
+ not attr.deprecated.renamed_to in registry_attribute_names
+ description := sprintf("Attribute '%s' was renamed to '%s', but the new attribute does not exist or is deprecated.", [attr.name, attr.deprecated.renamed_to])
+}
+
+# metric.deprecated.renamed_to must be another metric
+deny contains deprecation_violation(description, group.id, "") if {
+ group := input.groups[_]
+ group.type == "metric"
+ group.deprecated != null
+ group.deprecated.renamed_to != null
+
+ not group.deprecated.renamed_to in registry_metric_names
+ description := sprintf("Metric '%s' was renamed to '%s', but the new metric does not exist or is deprecated.", [group.metric_name, group.deprecated.renamed_to])
+}
+
+# event.deprecated.renamed_to must be another event
+deny contains deprecation_violation(description, group.id, "") if {
+ group := input.groups[_]
+ group.type == "event"
+ group.deprecated != null
+ group.deprecated.renamed_to != null
+
+ not group.deprecated.renamed_to in registry_event_names
+ description := sprintf("Event '%s' was renamed to '%s', but the new event does not exist or is deprecated.", [group.name, group.deprecated.renamed_to])
+}
+
+deprecation_violation(description, group, attr) = violation if {
+ violation := {
+ "id": description,
+ "type": "semconv_attribute",
+ "category": "deprecation_violation",
+ "attr": attr,
+ "group": group,
+ }
+}
diff --git a/policies/registry.rego b/policies/registry.rego
index 837d34c4ce..7067cc2c44 100644
--- a/policies/registry.rego
+++ b/policies/registry.rego
@@ -95,3 +95,4 @@ get_attribute_name(attr, group) := name if {
# if there was no prefix, we have a leading dot
name := trim(full_name, ".")
}
+
diff --git a/policies_test/attribute_name_collisions_test.rego b/policies_test/attribute_name_collisions_test.rego
index 2d08d0faf9..94659cc0f4 100644
--- a/policies_test/attribute_name_collisions_test.rego
+++ b/policies_test/attribute_name_collisions_test.rego
@@ -21,9 +21,9 @@ test_fails_on_namespace_collision if {
test_does_not_fail_on_deprecated_namespace_collision if {
collision := {"groups": [
{"id": "test1", "attributes": [{"name": "test.namespace.id"}]},
- {"id": "test2", "attributes": [{"name": "test.namespace", "deprecated": "replaced by foo.bar.baz"}]},
+ {"id": "test2", "attributes": [{"name": "test.namespace", "deprecated": {"reason" : "obsoleted"}}]},
- {"id": "test3", "attributes": [{"name": "another_test.namespace.id", "deprecated": "replaced by another_test.namespace"}]},
+ {"id": "test3", "attributes": [{"name": "another_test.namespace.id", "deprecated": {"reason" : "renamed", "renamed_to": "another_test.namespace"}}]},
{"id": "test4", "attributes": [{"name": "another_test.namespace"}]},
]}
count(deny) == 0 with input as collision
diff --git a/policies_test/deprecation_test.rego b/policies_test/deprecation_test.rego
new file mode 100644
index 0000000000..b86d5856d6
--- /dev/null
+++ b/policies_test/deprecation_test.rego
@@ -0,0 +1,54 @@
+package after_resolution
+import future.keywords
+
+test_fails_on_attribute_renamed_to_not_existing_attribute if {
+ count(deny) >= 1 with input as {"groups": [
+ {
+ "id": "deprecation.test", "stability": "development", "type": "attribute_group",
+ "attributes": [
+ {"name": "test.me", "stability": "development", "deprecated": {"reason": "renamed", "renamed_to": "some.other.name"}}
+ ]
+ },
+ {
+ "id": "metric.some.other.name", "type": "metric", "metric_name": "some.other.name", "stability": "rc"
+ }
+ ]}
+}
+
+
+test_fails_on_attribute_renamed_to_deprecated_attribute if {
+ count(deny) >= 1 with input as {"groups": [
+ {
+ "id": "deprecation.test", "stability": "development", "type": "attribute_group",
+ "attributes": [
+ {"name": "test.me", "stability": "development", "deprecated": {"reason": "renamed", "renamed_to": "some.other.name"}},
+ {"name": "some.other.name", "stability": "development", "deprecated": {"reason": "obsoleted"}}
+
+ ]
+ },
+ ]}
+}
+
+
+test_fails_on_metric_renamed_to_not_existing_metric if {
+ count(deny) >= 1 with input as {"groups": [
+ {
+ "id": "metric.test.me", "type": "metric", "metric_name": "test.me", "stability": "rc", "deprecated": {"reason": "renamed", "renamed_to": "some.other.name"}
+ },
+ {
+ "id": "deprecation.test", "stability": "development", "type": "attribute_group",
+ "attributes": [ {"id": "some.other.name", "stability": "development"}]
+ }
+ ]}
+}
+
+test_fails_on_metric_renamed_to_deprecated_metric if {
+ count(deny) >= 1 with input as {"groups": [
+ {
+ "id": "metric.test.me", "type": "metric", "metric_name": "test.me", "stability": "rc", "deprecated": {"reason": "renamed", "renamed_to": "some.other.name"}
+ },
+ {
+ "id": "metric.some.other.name", "type": "metric", "metric_name": "some.other.name", "stability": "rc", "deprecated": {"reason": "obsoleted"}
+ }
+ ]}
+}
diff --git a/templates/registry/markdown/attribute_namespace.md.j2 b/templates/registry/markdown/attribute_namespace.md.j2
index 5ab31b65b7..1d90772635 100644
--- a/templates/registry/markdown/attribute_namespace.md.j2
+++ b/templates/registry/markdown/attribute_namespace.md.j2
@@ -42,7 +42,7 @@
| Attribute | Type | Description | Examples | Stability |
|---|---|---|---|---|
{%- for attribute in group.attributes | sort(attribute="name") %}{% set attr_anchor = attribute.name | kebab_case %}
-| `{{ attrs.name(attribute) }}` | {{ attrs.type(attribute) }} | {{ attribute.brief | trim }}{{ notes.add({"note": attribute.note, "name": attrs.name(attribute)}) }} | {{ examples.format(attribute) | trim }} | {{ stability.badge(attribute.stability, attribute.deprecated) | trim }} |
+| `{{ attrs.name(attribute) }}` | {{ attrs.type(attribute) }} | {{ attribute.brief | trim }}{{ notes.add({"note": attribute.note, "name": attrs.name(attribute)}) }} | {{ examples.format(attribute) | trim }} | {{ stability.badge(attribute.stability, attribute.deprecated, attribute.brief) | trim }} |
{%- endfor %}
{{ notes.render() }}
{%- for enum in group.attributes | sort(attribute="name") %}
diff --git a/templates/registry/markdown/attribute_table.j2 b/templates/registry/markdown/attribute_table.j2
index 5b936f2784..48774fa771 100644
--- a/templates/registry/markdown/attribute_table.j2
+++ b/templates/registry/markdown/attribute_table.j2
@@ -8,6 +8,6 @@
{#- Macro for creating attribute table -#}
{% macro generate(attributes, tag_filter, attribute_registry_base_url, lineage_attributes) %}{% if (tag_filter | length == 0) %}{% set filtered_attributes = attributes %}{% else %}{% set filtered_attributes = attributes | selectattr("tag", "in", tag_filter) %}{% endif %}{% if filtered_attributes | length > 0 %}| Attribute | Type | Description | Examples | [Requirement Level](https://opentelemetry.io/docs/specs/semconv/general/attribute-requirement-level/) | Stability |
|---|---|---|---|---|---|
-{% for attribute in filtered_attributes | attribute_sort %}| {{ attrs.name_with_link(attribute, attribute_registry_base_url, lineage_attributes) }} | {{ attrs.type(attribute) }} | {{ attribute.brief | trim }}{{ notes.add({"note": attribute.note, "name": attrs.name(attribute)}) }} | {{ examples.format(attribute) | trim }} | {{ requirement.render({"level": attribute.requirement_level, "name": attrs.name(attribute)}, notes) | trim }} | {{ stability.badge(attribute.stability, attribute.deprecated) | trim }} |
+{% for attribute in filtered_attributes | attribute_sort %}| {{ attrs.name_with_link(attribute, attribute_registry_base_url, lineage_attributes) }} | {{ attrs.type(attribute) }} | {{ attribute.brief | trim }}{{ notes.add({"note": attribute.note, "name": attrs.name(attribute)}) }} | {{ examples.format(attribute) | trim }} | {{ requirement.render({"level": attribute.requirement_level, "name": attrs.name(attribute)}, notes) | trim }} | {{ stability.badge(attribute.stability, attribute.deprecated, attribute.brief) | trim }} |
{% endfor %}{{ notes.render() }}{{ sampling.snippet(filtered_attributes, attribute_registry_base_url, lineage_attributes) }}{{ enums.tables(filtered_attributes | selectattr("type", "mapping"), notes) }}
{% endif %}{% endmacro %}
diff --git a/templates/registry/markdown/body_field_table.j2 b/templates/registry/markdown/body_field_table.j2
index b600f6dd7f..169ecb6428 100644
--- a/templates/registry/markdown/body_field_table.j2
+++ b/templates/registry/markdown/body_field_table.j2
@@ -13,6 +13,6 @@
{#- Macro for creating body table -#}
{% macro generate(fields) %}{% if (fields | length > 0) %}{% set ns = namespace(flat=[])%}{% set _ = flatten(fields, ns, 0) %}| Body Field | Type | Description | Examples | [Requirement Level](https://opentelemetry.io/docs/specs/semconv/general/attribute-requirement-level/) | Stability |
|---|---|---|---|---|---|
-{% for f in ns.flat %}| {{ field_name(f.field, f.depth) }} | {{ f.field.type }} | {{ f.field.brief | trim }}{{ notes.add({"note": f.field.note}) }} | {{ examples.format(f.field) | trim }} | {{ requirement.render({"level": f.field.requirement_level, "name": f.field.id}, notes) | trim }} | {{ stability.badge(f.field.stability, f.field.deprecated) | trim }} |
+{% for f in ns.flat %}| {{ field_name(f.field, f.depth) }} | {{ f.field.type }} | {{ f.field.brief | trim }}{{ notes.add({"note": f.field.note}) }} | {{ examples.format(f.field) | trim }} | {{ requirement.render({"level": f.field.requirement_level, "name": f.field.id}, notes) | trim }} | {{ stability.badge(f.field.stability, f.field.deprecated, f.field.brief) | trim }} |
{% endfor %}{{ notes.render() }}{{ enums.field_tables(ns.flat | map(attribute="field") | selectattr("type", "eq", "enum"), notes) -}}
{%- endif %}{% endmacro %}
diff --git a/templates/registry/markdown/enum_macros.j2 b/templates/registry/markdown/enum_macros.j2
index d20327e14b..eb227493fc 100644
--- a/templates/registry/markdown/enum_macros.j2
+++ b/templates/registry/markdown/enum_macros.j2
@@ -9,7 +9,7 @@
|---|---|---|
{% for espec in enum.type.members | sort(attribute='value') %}
{%- if filter(espec) == "True" -%}
-| `{{ espec.value }}` | {{ (espec.brief or espec.id) | trim }}{{ notes.add({"note": espec.note}) }} | {{ stability.badge(espec.stability, espec.deprecated) }} |
+| `{{ espec.value }}` | {{ (espec.brief or espec.id) | trim }}{{ notes.add({"note": espec.note}) }} | {{ stability.badge(espec.stability, espec.deprecated, espec.brief) }} |
{% endif %}{% endfor %}{{ notes.render() }}{% endmacro %}
{% macro tables(enums, notes) -%}
{% for enum in enums | sort(attribute="name") -%}
@@ -22,7 +22,7 @@
|---|---|---|
{% for espec in enum.members | sort(attribute='value') %}
{%- if filter(espec) == "True" -%}
-| `{{ espec.value }}` | {{ (espec.brief or espec.id) | trim }}{{ notes.add({"note": espec.note}) }} | {{ stability.badge(espec.stability, espec.deprecated) }} |
+| `{{ espec.value }}` | {{ (espec.brief or espec.id) | trim }}{{ notes.add({"note": espec.note}) }} | {{ stability.badge(espec.stability, espec.deprecated, espec.brief) }} |
{% endif %}{% endfor %}{{ notes.render() }}{% endmacro %}
{% macro field_tables(enums, notes) -%}
{% for enum in enums | sort(attribute="id") -%}
diff --git a/templates/registry/markdown/event_macros.j2 b/templates/registry/markdown/event_macros.j2
index c0697d3fc8..ad054ace31 100644
--- a/templates/registry/markdown/event_macros.j2
+++ b/templates/registry/markdown/event_macros.j2
@@ -1,7 +1,7 @@
{#- Macros for simplifying creating "Event" documentation. -#}
{% import 'stability.j2' as stability %}
{% import 'body_field_table.j2' as body_table %}
-{% macro header(event) %}**Status:** {{ stability.badge(event.stability, event.deprecated) }}
+{% macro header(event) %}**Status:** {{ stability.badge(event.stability, event.deprecated, event.brief) }}
The event name MUST be `{{ event.name }}`.
diff --git a/templates/registry/markdown/metric_table.j2 b/templates/registry/markdown/metric_table.j2
index 5783398de3..60006ff6fc 100644
--- a/templates/registry/markdown/metric_table.j2
+++ b/templates/registry/markdown/metric_table.j2
@@ -4,5 +4,5 @@
{% macro print_entities(associations) %}{%- for e in associations %}{%if loop.first == false %}; {% endif %}`{{ e | trim }}`{%- endfor %}{% endmacro %}
{% macro generate(group) %}| Name | Instrument Type | Unit (UCUM) | Description | Stability | Entity Associations |
| -------- | --------------- | ----------- | -------------- | --------- | ------ |
-| `{{ group.metric_name }}` | {{ metrics.instrument(group.instrument) | trim }} | `{{ group.unit }}` | {{ group.brief | trim }}{{ notes.add({"note": group.note}) }} | {{ stability.badge(group.stability, group.deprecated) | trim }} | {{ print_entities(group.entity_associations) }} |
+| `{{ group.metric_name }}` | {{ metrics.instrument(group.instrument) | trim }} | `{{ group.unit }}` | {{ group.brief | trim }}{{ notes.add({"note": group.note}) }} | {{ stability.badge(group.stability, group.deprecated, group.brief) | trim }} | {{ print_entities(group.entity_associations) }} |
{{ notes.render() }}{% endmacro %}
diff --git a/templates/registry/markdown/resource_macros.j2 b/templates/registry/markdown/resource_macros.j2
index f19680cbd8..70b0e1ac1c 100644
--- a/templates/registry/markdown/resource_macros.j2
+++ b/templates/registry/markdown/resource_macros.j2
@@ -2,9 +2,9 @@
{% import 'stability.j2' as stability %}
{% macro real_stability(resource) %}
{% if resource.attributes | map(attribute='stability') | unique | length > 1 -%}
-{{ stability.badge("mixed", "") }}
+{{ stability.badge("mixed", "", "") }}
{%- else -%}
-{{ stability.badge(resource.stability, resource.deprecated) }}
+{{ stability.badge(resource.stability, resource.deprecated, resource.brief) }}
{%- endif %}
{% endmacro %}
{% macro header(resource) %}
diff --git a/templates/registry/markdown/stability.j2 b/templates/registry/markdown/stability.j2
index cc9ed7bde6..b4d019e233 100644
--- a/templates/registry/markdown/stability.j2
+++ b/templates/registry/markdown/stability.j2
@@ -1,5 +1,5 @@
-{% macro badge(stability, deprecated) -%}
-{%- if deprecated %}
{{ deprecated.note | trim }}
+{% macro badge(stability, deprecated, note) -%}
+{%- if deprecated %}
{{ deprecated_note(deprecated, note) }}
{%- elif stability == "mixed" %}
{%- elif stability == "stable" %}
{%- elif stability == "release_candidate" %}
@@ -9,3 +9,6 @@
{%- else %}{{ "Unknown stability." }}
{%- endif %}
{%- endmacro %}
+
+
+{% macro deprecated_note(deprecated, note) %}{{ (deprecated.note if deprecated.note is defined else note) | trim }}{%- endmacro %}