Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RabbitMQ: Specify how to populate messaging.destination.name #1531

Open
wants to merge 11 commits into
base: main
Choose a base branch
from
4 changes: 4 additions & 0 deletions .chloggen/rabbitmq-destination-name.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
change_type: breaking
component: messaging
note: "RabbitMQ: Specify how to populate `messaging.destination.name`"
issues: [1529]
17 changes: 15 additions & 2 deletions docs/messaging/rabbitmq.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,21 @@ The Semantic Conventions for [RabbitMQ](https://www.rabbitmq.com/) extend and ov

## RabbitMQ 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.
### Destination name

In RabbitMQ, the destination is defined by an *exchange*, a *routing key* and
for consumers, a *queue*.
`messaging.destination.name` MUST be set to:

**Producers**

- `{exchange}:{routing key}` when both values are present and non-empty.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's consider . to match what we do in DBs

If any has an empty value (e.g., the default exchange is used) it SHOULD be omitted.
- Otherwise: `amq.default`

**Consumers**
- `{exchange}:{routing key}:{queue}` when all values are present and non-empty.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe check if routing key and queue are the same and populate just one

If any has an empty value (e.g., the default exchange is used) it SHOULD be omitted.

<!-- semconv messaging.rabbitmq -->
<!-- NOTE: THIS TEXT IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
Expand Down
Loading