Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
lmolkova committed Feb 7, 2024
1 parent 34f2d2e commit 6b70542
Show file tree
Hide file tree
Showing 4 changed files with 51 additions and 11 deletions.
30 changes: 26 additions & 4 deletions docs/messaging/azure-messaging.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,33 @@
<!--- Hugo front matter used to generate the website version of this page:
linkTitle: Google Cloud Pub/Sub
linkTitle: Azure Messaging Systems
--->

# Semantic Conventions for Azure Messaging systems
# Semantic Conventions for Azure Messaging Systems

**Status**: [Experimental][DocumentStatus]

<!-- toc -->

- [Azure Service Bus](#azure-service-bus)
* [Service Bus Attributes](#service-bus-attributes)
* [Service Bus Metrics](#service-bus-metrics)
+ [Metric: `messaging.publish.duration`](#metric-messagingpublishduration)
+ [Metric: `messaging.publish.messages`](#metric-messagingpublishmessages)
+ [Metric: `messaging.deliver.duration`](#metric-messagingdeliverduration)
+ [Metric: `messaging.receive.duration`](#metric-messagingreceiveduration)
+ [Metric: `messaging.receive.messages`](#metric-messagingreceivemessages)
- [Azure Event Hubs](#azure-event-hubs)
* [Event Hubs Attributes](#event-hubs-attributes)
* [Event Hubs Metrics](#event-hubs-metrics)
+ [Metric: `messaging.publish.duration`](#metric-messagingpublishduration-1)
+ [Metric: `messaging.publish.messages`](#metric-messagingpublishmessages-1)
+ [Metric: `messaging.deliver.duration`](#metric-messagingdeliverduration-1)
+ [Metric: `messaging.deliver.messages`](#metric-messagingdelivermessages)
+ [Metric: `messaging.receive.duration`](#metric-messagingreceiveduration-1)
+ [Metric: `messaging.receive.messages`](#metric-messagingreceivemessages-1)

<!-- tocstop -->

The Semantic Conventions for [Azure Service Bus](https://learn.microsoft.com/azure/service-bus-messaging/service-bus-messaging-overview) and [Azure Event Hubs](https://learn.microsoft.com/azure/event-hubs/event-hubs-about) extend and override the [Messaging Semantic Conventions](README.md) that describe common messaging operations attributes in addition to the Semantic Conventions described on this page.

## Azure Service Bus
Expand Down Expand Up @@ -58,7 +80,7 @@ the broker doesn't have such notion, the destination name SHOULD uniquely identi
**[12]:** When observed from the client side, and when communicating through an intermediary, `server.port` SHOULD represent the server port behind any intermediaries, for example proxies, if it's available.
<!-- endsemconv -->

### Metrics
### Service Bus Metrics

#### Metric: `messaging.publish.duration`

Expand Down Expand Up @@ -164,7 +186,7 @@ the broker doesn't have such notion, the destination name SHOULD uniquely identi
**[11]:** When observed from the client side, and when communicating through an intermediary, `server.port` SHOULD represent the server port behind any intermediaries, for example proxies, if it's available.
<!-- endsemconv -->

### Metrics
### Event Hubs Metrics

#### Metric: `messaging.publish.duration`

Expand Down
11 changes: 8 additions & 3 deletions docs/messaging/kafka.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,12 @@ linkTitle: Kafka

<!-- toc -->

- [Span attributes](#span-attributes)
- [Attributes](#attributes)
- [Metrics](#metrics)
* [Metric: `messaging.publish.duration`](#metric-messagingpublishduration)
* [Metric: `messaging.publish.messages`](#metric-messagingpublishmessages)
* [Metric: `messaging.receive.duration`](#metric-messagingreceiveduration)
* [Metric: `messaging.receive.messages`](#metric-messagingreceivemessages)
- [Examples](#examples)
* [Apache Kafka with Quarkus or Spring Boot Example](#apache-kafka-with-quarkus-or-spring-boot-example)

Expand Down Expand Up @@ -100,7 +105,7 @@ This metric follows the common [messaging.receive.messages](./messaging-metrics.
* `messaging.kafka.destination.partition`
* `messaging.kafka.consumer.group`

## Span examples
## Examples

### Apache Kafka with Quarkus or Spring Boot Example

Expand Down Expand Up @@ -141,4 +146,4 @@ Process CB: | Span Rcv2 |
| `messaging.kafka.message.offset` | `"12"` | `"12"` | `"12"` | `"32"` | `"32"` |

[DocumentStatus]: https://github.com/open-telemetry/opentelemetry-specification/tree/v1.26.0/specification/document-status.md
[MetricRequired]: https://github.com/open-telemetry/opentelemetry-specification/blob/v1.26.0/specification/metrics/metric-requirement-level.md#required
[MetricRequired]: https://github.com/open-telemetry/opentelemetry-specification/blob/v1.26.0/specification/metrics/metric-requirement-level.md#required
19 changes: 16 additions & 3 deletions docs/messaging/rabbitmq.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,23 @@ linkTitle: RabbitMQ

**Status**: [Experimental][DocumentStatus]

<!-- toc -->

- [Attributes](#attributes)
- [Metrics](#metrics)
* [Metric: `messaging.publish.duration`](#metric-messagingpublishduration)
* [Metric: `messaging.deliver.duration`](#metric-messagingdeliverduration)
* [Metric: `messaging.receive.duration`](#metric-messagingreceiveduration)

<!-- tocstop -->

The Semantic Conventions for [RabbitMQ](https://www.rabbitmq.com/) extend and override the [Messaging Semantic Conventions](README.md)
that describe common messaging operations attributes in addition to the Semantic Conventions
described on this page.

`messaging.system` MUST be set to `"rabbitmq"`.

## RabbitMQ attributes
## Attributes

In RabbitMQ, the destination is defined by an *exchange* and a *routing key*.
`messaging.destination.name` MUST be set to the name of the exchange. This will be an empty string if the default exchange is used.
Expand All @@ -34,8 +44,9 @@ This metric is [required][MetricRequired]
This metric follows the common [messaging.publish.duration](./messaging-metrics.md#metric-messagingpublishduration) definition.

**Notes:**

- `messaging.publish.messages` metric is not reported: RabbitMQ doesn't support batch publish, therefore the count of published messages can be derived from `messaging.publish.duration` metric.
- In addition to generic attributes defined for the metric, RabbitMQ instrumentations SHOULD report the following attributes (according to their [requirement levels](#rabbitmq-attributes)):
- In addition to generic attributes defined for the metric, RabbitMQ instrumentations SHOULD report the following attributes (according to their [requirement levels](#attributes)):
* `messaging.rabbitmq.destination.routing_key`

### Metric: `messaging.deliver.duration`
Expand All @@ -47,6 +58,7 @@ This metric is [required][MetricRequired] when consume API is used.
This metric follows the common [messaging.receive.duration](./messaging-metrics.md#metric-messagingdeliverduration) definition.

**Notes:**

- `messaging.deliver.messages` metric is not reported: RabbitMQ doesn't support batch consumption, therefore the count of delivered messages can be derived from `messaging.deliver.duration` metric.

### Metric: `messaging.receive.duration`
Expand All @@ -58,7 +70,8 @@ This metric is [required][MetricRequired] if pull API is used.
This metric follows the common [messaging.receive.duration](./messaging-metrics.md#metric-messagingdeliverduration) definition.

**Notes:**

- `messaging.receive.messages` metric is not reported: RabbitMQ doesn't support batch receive, therefore the count of received messages can be derived from `messaging.receive.duration` metric.

[DocumentStatus]: https://github.com/open-telemetry/opentelemetry-specification/tree/v1.26.0/specification/document-status.md
[MetricRequired]: https://github.com/open-telemetry/opentelemetry-specification/blob/v1.26.0/specification/metrics/metric-requirement-level.md#required
[MetricRequired]: https://github.com/open-telemetry/opentelemetry-specification/blob/v1.26.0/specification/metrics/metric-requirement-level.md#required
2 changes: 1 addition & 1 deletion model/trace/messaging.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -240,4 +240,4 @@ groups:
- ref: messaging.destination.name
- ref: messaging.message.id
- ref: messaging.operation
- ref: server.address
- ref: server.address

0 comments on commit 6b70542

Please sign in to comment.