From 2127fbd7dacbabbda28d23c1078f235f96c34da7 Mon Sep 17 00:00:00 2001 From: Alexander Wert Date: Tue, 14 Nov 2023 12:45:16 +0100 Subject: [PATCH 1/6] Changed `messaging.system` attribute type to an open enum Signed-off-by: Alexander Wert --- docs/attributes-registry/messaging.md | 14 ++++++++++++- docs/messaging/messaging-spans.md | 14 ++++++++++++- model/registry/messaging.yaml | 29 ++++++++++++++++++++++++--- 3 files changed, 52 insertions(+), 5 deletions(-) diff --git a/docs/attributes-registry/messaging.md b/docs/attributes-registry/messaging.md index 27bbae84c4..5d1aa365a7 100644 --- a/docs/attributes-registry/messaging.md +++ b/docs/attributes-registry/messaging.md @@ -36,7 +36,7 @@ | `messaging.rocketmq.message.tag` | string | The secondary classifier of message besides topic. | `tagA` | | `messaging.rocketmq.message.type` | string | Type of message. | `normal` | | `messaging.rocketmq.namespace` | string | Namespace of RocketMQ resources, resources in different namespaces are individual. | `myNamespace` | -| `messaging.system` | string | A string identifying the messaging system. | `kafka`; `rabbitmq`; `rocketmq`; `activemq` | +| `messaging.system` | string | An identifier for the messaging system being used. See below for a list of well-known identifiers. | `activemq` | **[1]:** Instrumentations SHOULD NOT set `messaging.batch.message_count` on spans that operate with a single message. When a messaging client library supports both batch and single-message API for the same operation, instrumentations SHOULD use `messaging.batch.message_count` for batching APIs and SHOULD NOT use it for single-message APIs. @@ -82,4 +82,16 @@ size should be used. | `fifo` | FIFO message | | `delay` | Delay message | | `transaction` | Transaction message | + +`messaging.system` has the following list of well-known values. If one of them applies, then the respective value MUST be used, otherwise a custom value MAY be used. + +| Value | Description | +|---|---| +| `activemq` | ActiveMQ | +| `AmazonSQS` | Amazon Simple Queue Service (SQS) | +| `gcp_pubsub` | Google Cloud Pub/Sub | +| `jms` | Java Message Service | +| `kafka` | Kafka | +| `rabbitmq` | RabbitMQ | +| `rocketmq` | RocketMQ | diff --git a/docs/messaging/messaging-spans.md b/docs/messaging/messaging-spans.md index fa95e8c3b2..41fe469981 100644 --- a/docs/messaging/messaging-spans.md +++ b/docs/messaging/messaging-spans.md @@ -287,7 +287,7 @@ messages were received). For each message it accounts for, the "Deliver" or | [`messaging.message.envelope.size`](../attributes-registry/messaging.md) | int | The size of the message body and metadata in bytes. [12] | `2738` | Recommended: [13] | | [`messaging.message.id`](../attributes-registry/messaging.md) | string | A value used by the messaging system as an identifier for the message, represented as a string. | `452a7c7c7c7048c2f887f61572b18fc2` | Recommended: [14] | | [`messaging.operation`](../attributes-registry/messaging.md) | string | A string identifying the kind of messaging operation. [15] | `publish` | Required | -| [`messaging.system`](../attributes-registry/messaging.md) | string | A string identifying the messaging system. | `kafka`; `rabbitmq`; `rocketmq`; `activemq` | Required | +| [`messaging.system`](../attributes-registry/messaging.md) | string | An identifier for the messaging system being used. See below for a list of well-known identifiers. | `activemq` | Required | | [`network.peer.address`](../attributes-registry/network.md) | string | Peer address of the network connection - IP address or Unix domain socket name. | `10.1.2.80`; `/tmp/my.sock` | Recommended | | [`network.peer.port`](../attributes-registry/network.md) | int | Peer port number of the network connection. | `65123` | Recommended: If `network.peer.address` is set. | | [`network.protocol.name`](../attributes-registry/network.md) | string | [OSI application layer](https://osi-model.com/application-layer/) or non-OSI equivalent. [16] | `amqp`; `mqtt` | Recommended | @@ -352,6 +352,18 @@ different processes could be listening on TCP port 12345 and UDP port 12345. | `receive` | One or more messages are requested by a consumer. This operation refers to pull-based scenarios, where consumers explicitly call methods of messaging SDKs to receive messages. | | `deliver` | One or more messages are passed to a consumer. This operation refers to push-based scenarios, where consumer register callbacks which get called by messaging SDKs. | +`messaging.system` has the following list of well-known values. If one of them applies, then the respective value MUST be used, otherwise a custom value MAY be used. + +| Value | Description | +|---|---| +| `activemq` | ActiveMQ | +| `AmazonSQS` | Amazon Simple Queue Service (SQS) | +| `gcp_pubsub` | Google Cloud Pub/Sub | +| `jms` | Java Message Service | +| `kafka` | Kafka | +| `rabbitmq` | RabbitMQ | +| `rocketmq` | RocketMQ | + `network.transport` has the following list of well-known values. If one of them applies, then the respective value MUST be used, otherwise a custom value MAY be used. | Value | Description | diff --git a/model/registry/messaging.yaml b/model/registry/messaging.yaml index f7dd6257ab..ff56992aff 100644 --- a/model/registry/messaging.yaml +++ b/model/registry/messaging.yaml @@ -203,6 +203,29 @@ groups: Namespace of RocketMQ resources, resources in different namespaces are individual. examples: 'myNamespace' - id: system - type: string - brief: 'A string identifying the messaging system.' - examples: ['kafka', 'rabbitmq', 'rocketmq', 'activemq'] + brief: > + An identifier for the messaging system being used. See below for a list of well-known identifiers. + type: + allow_custom_values: true + members: + - id: activemq + value: 'activemq' + brief: 'ActiveMQ' + - id: amazonsqs + value: 'AmazonSQS' + brief: 'Amazon Simple Queue Service (SQS)' + - id: gcp_pubsub + value: 'gcp_pubsub' + brief: 'Google Cloud Pub/Sub' + - id: jms + value: 'jms' + brief: 'Java Message Service' + - id: kafka + value: 'kafka' + brief: 'Kafka' + - id: rabbitmq + value: 'rabbitmq' + brief: 'RabbitMQ' + - id: rocketmq + value: 'rocketmq' + brief: 'RocketMQ' From ec013360d3621edcbe2a164317942bcc229a05bf Mon Sep 17 00:00:00 2001 From: Alexander Wert Date: Tue, 14 Nov 2023 13:54:45 +0100 Subject: [PATCH 2/6] Added changelog entry Signed-off-by: Alexander Wert --- CHANGELOG.md | 2 ++ model/registry/messaging.yaml | 6 +++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 44baae1131..21cbd4c1bb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,8 @@ release. ([#317](https://github.com/open-telemetry/semantic-conventions/pull/317)) - BREAKING: Change type of `host.cpu.model.id` and `host.cpu.model.family` to string. ([#495](https://github.com/open-telemetry/semantic-conventions/issues/495)) +- Changed `messaging.system` attribute type to an open enum + ([#517](https://github.com/open-telemetry/semantic-conventions/pull/517)) ### Features diff --git a/model/registry/messaging.yaml b/model/registry/messaging.yaml index ff56992aff..c6162da3bd 100644 --- a/model/registry/messaging.yaml +++ b/model/registry/messaging.yaml @@ -210,7 +210,7 @@ groups: members: - id: activemq value: 'activemq' - brief: 'ActiveMQ' + brief: 'Apache ActiveMQ' - id: amazonsqs value: 'AmazonSQS' brief: 'Amazon Simple Queue Service (SQS)' @@ -222,10 +222,10 @@ groups: brief: 'Java Message Service' - id: kafka value: 'kafka' - brief: 'Kafka' + brief: 'Apache Kafka' - id: rabbitmq value: 'rabbitmq' brief: 'RabbitMQ' - id: rocketmq value: 'rocketmq' - brief: 'RocketMQ' + brief: 'Apache RocketMQ' From 9330222f949a727d1f9e41ddd957caf1a06b131f Mon Sep 17 00:00:00 2001 From: Alexander Wert Date: Tue, 14 Nov 2023 14:28:02 +0100 Subject: [PATCH 3/6] fixed table rendering Signed-off-by: Alexander Wert --- docs/attributes-registry/messaging.md | 6 +++--- docs/messaging/messaging-spans.md | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/docs/attributes-registry/messaging.md b/docs/attributes-registry/messaging.md index 5d1aa365a7..837982dd96 100644 --- a/docs/attributes-registry/messaging.md +++ b/docs/attributes-registry/messaging.md @@ -87,11 +87,11 @@ size should be used. | Value | Description | |---|---| -| `activemq` | ActiveMQ | +| `activemq` | Apache ActiveMQ | | `AmazonSQS` | Amazon Simple Queue Service (SQS) | | `gcp_pubsub` | Google Cloud Pub/Sub | | `jms` | Java Message Service | -| `kafka` | Kafka | +| `kafka` | Apache Kafka | | `rabbitmq` | RabbitMQ | -| `rocketmq` | RocketMQ | +| `rocketmq` | Apache RocketMQ | diff --git a/docs/messaging/messaging-spans.md b/docs/messaging/messaging-spans.md index 41fe469981..9c48c9c18e 100644 --- a/docs/messaging/messaging-spans.md +++ b/docs/messaging/messaging-spans.md @@ -356,13 +356,13 @@ different processes could be listening on TCP port 12345 and UDP port 12345. | Value | Description | |---|---| -| `activemq` | ActiveMQ | +| `activemq` | Apache ActiveMQ | | `AmazonSQS` | Amazon Simple Queue Service (SQS) | | `gcp_pubsub` | Google Cloud Pub/Sub | | `jms` | Java Message Service | -| `kafka` | Kafka | +| `kafka` | Apache Kafka | | `rabbitmq` | RabbitMQ | -| `rocketmq` | RocketMQ | +| `rocketmq` | Apache RocketMQ | `network.transport` has the following list of well-known values. If one of them applies, then the respective value MUST be used, otherwise a custom value MAY be used. From 46b024a5826b15d60873d34620766918278d807f Mon Sep 17 00:00:00 2001 From: Alexander Wert Date: Tue, 14 Nov 2023 15:03:57 +0100 Subject: [PATCH 4/6] changed AmazonSQS to the desired value Signed-off-by: Alexander Wert --- docs/attributes-registry/messaging.md | 2 +- docs/messaging/messaging-spans.md | 2 +- model/registry/messaging.yaml | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/attributes-registry/messaging.md b/docs/attributes-registry/messaging.md index 837982dd96..3b14585cd1 100644 --- a/docs/attributes-registry/messaging.md +++ b/docs/attributes-registry/messaging.md @@ -88,7 +88,7 @@ size should be used. | Value | Description | |---|---| | `activemq` | Apache ActiveMQ | -| `AmazonSQS` | Amazon Simple Queue Service (SQS) | +| `amazon_sqs` | Amazon Simple Queue Service (SQS) | | `gcp_pubsub` | Google Cloud Pub/Sub | | `jms` | Java Message Service | | `kafka` | Apache Kafka | diff --git a/docs/messaging/messaging-spans.md b/docs/messaging/messaging-spans.md index 9c48c9c18e..a05e3098e2 100644 --- a/docs/messaging/messaging-spans.md +++ b/docs/messaging/messaging-spans.md @@ -357,7 +357,7 @@ different processes could be listening on TCP port 12345 and UDP port 12345. | Value | Description | |---|---| | `activemq` | Apache ActiveMQ | -| `AmazonSQS` | Amazon Simple Queue Service (SQS) | +| `amazon_sqs` | Amazon Simple Queue Service (SQS) | | `gcp_pubsub` | Google Cloud Pub/Sub | | `jms` | Java Message Service | | `kafka` | Apache Kafka | diff --git a/model/registry/messaging.yaml b/model/registry/messaging.yaml index c6162da3bd..5f21df6f6b 100644 --- a/model/registry/messaging.yaml +++ b/model/registry/messaging.yaml @@ -211,8 +211,8 @@ groups: - id: activemq value: 'activemq' brief: 'Apache ActiveMQ' - - id: amazonsqs - value: 'AmazonSQS' + - id: amazon_sqs + value: 'amazon_sqs' brief: 'Amazon Simple Queue Service (SQS)' - id: gcp_pubsub value: 'gcp_pubsub' From 3ac990ebbfba140bfba29bf118ff8d81e0ebc320 Mon Sep 17 00:00:00 2001 From: Alexander Wert Date: Tue, 14 Nov 2023 16:04:16 +0100 Subject: [PATCH 5/6] changed to aws_sqs Signed-off-by: Alexander Wert --- docs/attributes-registry/messaging.md | 2 +- docs/messaging/messaging-spans.md | 2 +- model/registry/messaging.yaml | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/attributes-registry/messaging.md b/docs/attributes-registry/messaging.md index 3b14585cd1..0f09d543b1 100644 --- a/docs/attributes-registry/messaging.md +++ b/docs/attributes-registry/messaging.md @@ -88,7 +88,7 @@ size should be used. | Value | Description | |---|---| | `activemq` | Apache ActiveMQ | -| `amazon_sqs` | Amazon Simple Queue Service (SQS) | +| `aws_sqs` | Amazon Simple Queue Service (SQS) | | `gcp_pubsub` | Google Cloud Pub/Sub | | `jms` | Java Message Service | | `kafka` | Apache Kafka | diff --git a/docs/messaging/messaging-spans.md b/docs/messaging/messaging-spans.md index a05e3098e2..1fcc55c60f 100644 --- a/docs/messaging/messaging-spans.md +++ b/docs/messaging/messaging-spans.md @@ -357,7 +357,7 @@ different processes could be listening on TCP port 12345 and UDP port 12345. | Value | Description | |---|---| | `activemq` | Apache ActiveMQ | -| `amazon_sqs` | Amazon Simple Queue Service (SQS) | +| `aws_sqs` | Amazon Simple Queue Service (SQS) | | `gcp_pubsub` | Google Cloud Pub/Sub | | `jms` | Java Message Service | | `kafka` | Apache Kafka | diff --git a/model/registry/messaging.yaml b/model/registry/messaging.yaml index 5f21df6f6b..9da4cfbd2f 100644 --- a/model/registry/messaging.yaml +++ b/model/registry/messaging.yaml @@ -211,8 +211,8 @@ groups: - id: activemq value: 'activemq' brief: 'Apache ActiveMQ' - - id: amazon_sqs - value: 'amazon_sqs' + - id: aws_sqs + value: 'aws_sqs' brief: 'Amazon Simple Queue Service (SQS)' - id: gcp_pubsub value: 'gcp_pubsub' From 311876f67a9e99be808ac8c69511da5df176fb99 Mon Sep 17 00:00:00 2001 From: Alexander Wert Date: Wed, 15 Nov 2023 07:39:51 +0100 Subject: [PATCH 6/6] Added Azure messaging services Signed-off-by: Alexander Wert --- docs/attributes-registry/messaging.md | 3 +++ docs/messaging/messaging-spans.md | 3 +++ model/registry/messaging.yaml | 9 +++++++++ 3 files changed, 15 insertions(+) diff --git a/docs/attributes-registry/messaging.md b/docs/attributes-registry/messaging.md index 0f09d543b1..fe5523c85d 100644 --- a/docs/attributes-registry/messaging.md +++ b/docs/attributes-registry/messaging.md @@ -89,6 +89,9 @@ size should be used. |---|---| | `activemq` | Apache ActiveMQ | | `aws_sqs` | Amazon Simple Queue Service (SQS) | +| `azure_eventgrid` | Azure Event Grid | +| `azure_eventhubs` | Azure Event Hubs | +| `azure_servicebus` | Azure Service Bus | | `gcp_pubsub` | Google Cloud Pub/Sub | | `jms` | Java Message Service | | `kafka` | Apache Kafka | diff --git a/docs/messaging/messaging-spans.md b/docs/messaging/messaging-spans.md index 1fcc55c60f..19cfbc43e1 100644 --- a/docs/messaging/messaging-spans.md +++ b/docs/messaging/messaging-spans.md @@ -358,6 +358,9 @@ different processes could be listening on TCP port 12345 and UDP port 12345. |---|---| | `activemq` | Apache ActiveMQ | | `aws_sqs` | Amazon Simple Queue Service (SQS) | +| `azure_eventgrid` | Azure Event Grid | +| `azure_eventhubs` | Azure Event Hubs | +| `azure_servicebus` | Azure Service Bus | | `gcp_pubsub` | Google Cloud Pub/Sub | | `jms` | Java Message Service | | `kafka` | Apache Kafka | diff --git a/model/registry/messaging.yaml b/model/registry/messaging.yaml index 9da4cfbd2f..64dc6fe5a0 100644 --- a/model/registry/messaging.yaml +++ b/model/registry/messaging.yaml @@ -214,6 +214,15 @@ groups: - id: aws_sqs value: 'aws_sqs' brief: 'Amazon Simple Queue Service (SQS)' + - id: azure_eventgrid + value: 'azure_eventgrid' + brief: 'Azure Event Grid' + - id: azure_eventhubs + value: 'azure_eventhubs' + brief: 'Azure Event Hubs' + - id: azure_servicebus + value: 'azure_servicebus' + brief: 'Azure Service Bus' - id: gcp_pubsub value: 'gcp_pubsub' brief: 'Google Cloud Pub/Sub'