Skip to content

[Messaging] What to use for {destination} on span name when destination is temporary or anonymous #1532

Closed
@joaopgrassi

Description

@joaopgrassi

Area(s)

area:messaging

Is your change request related to a problem? Please describe.

In the current conventions for messaging Span name we have:

The {destination} SHOULD describe the entity that the operation is performed against and SHOULD adhere to one of the following values, provided they are accessible:

  1. messaging.destination.template SHOULD be used when it is available.
  2. messaging.destination.name SHOULD be used when the destination is known to be neither temporary nor anonymous.
  3. server.address:server.port SHOULD be used only for operations not targeting any specific destination(s).

But it is unclear what to use for {destination} if the destination is temporary or anonymous. Should it be used at all?

In the RabbitMQ Java instrumentation, when the destination is temporary, the messaging.destination.name attribute is populated with the value (temporary)., which raises the question if the same should be done for the span name.

Describe the solution you'd like

  • We should define what value to use for messaging.destination.name when the destination is temporary or anonymous to avoid inconsistency across instrumentation
  • We should define what the span name should look like when the destination is temporary or anonymous.

Describe alternatives you've considered

  • We can mention that when the destination is temporary or anonymous, messaging.destination.name should be set to something like (temporary) or (anonymous)
  • For the span name we CAN:
    • Say if the destination is either temporary or anonymous, and no other attributes are available {destination} should be omitted on the span name OR
    • Say if the destination is either temporary or anonymous, a placeholder of temporary or anonymous should be used for {destination} on the span name

Additional context

No response

Metadata

Metadata

Assignees

Type

No type

Projects

Status

V1 - Stable Semantics

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions