-
Notifications
You must be signed in to change notification settings - Fork 164
Span structure for messaging scenarios #220
Span structure for messaging scenarios #220
Conversation
aca9f0e
to
e191e53
Compare
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
Resolves #6779 In JMS you can have either the consumer receive span or the consumer process span (unlike Kafka, where the process span is always there and the receive span is just an addition) - in scenarios where polling (receive) is used, I think it makes sense to add links to the producer span to preserve the producer-consumer connection. Current messaging semantic conventions don't really describe a situation like this one, but the open-telemetry/oteps#220 OTEP mentions that links might be used in a scenario like this one - which makes me think that adding links here might be a not that bad idea.
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
Resolves open-telemetry#6779 In JMS you can have either the consumer receive span or the consumer process span (unlike Kafka, where the process span is always there and the receive span is just an addition) - in scenarios where polling (receive) is used, I think it makes sense to add links to the producer span to preserve the producer-consumer connection. Current messaging semantic conventions don't really describe a situation like this one, but the open-telemetry/oteps#220 OTEP mentions that links might be used in a scenario like this one - which makes me think that adding links here might be a not that bad idea.
Resolves open-telemetry#6779 In JMS you can have either the consumer receive span or the consumer process span (unlike Kafka, where the process span is always there and the receive span is just an addition) - in scenarios where polling (receive) is used, I think it makes sense to add links to the producer span to preserve the producer-consumer connection. Current messaging semantic conventions don't really describe a situation like this one, but the open-telemetry/oteps#220 OTEP mentions that links might be used in a scenario like this one - which makes me think that adding links here might be a not that bad idea.
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
Resolves open-telemetry#6779 In JMS you can have either the consumer receive span or the consumer process span (unlike Kafka, where the process span is always there and the receive span is just an addition) - in scenarios where polling (receive) is used, I think it makes sense to add links to the producer span to preserve the producer-consumer connection. Current messaging semantic conventions don't really describe a situation like this one, but the open-telemetry/oteps#220 OTEP mentions that links might be used in a scenario like this one - which makes me think that adding links here might be a not that bad idea.
dfc70e6
to
1d27d3c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
left a few (mostly) cosmetic suggestions. The only major question is how we go ahead with producer/consumer controversy in the spec.
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Finally found some time to review this. I think we are getting very close!
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Summary of this & all my previous reviews today: Mostly just copy-editing and a few very minor points. I did not review the examples. Overall mostly LGTM.
There is just one point that kept me from clicking "Approve", though it is also not a hard blocker: The "Trace structure" and "Span relationships" sections in combination might easily lead to redundancy or even contradictions in the current state. See #220 (comment)
The only other points that I'd like to point out specifically, but only because I made too many totally trivial nitpicks and these are a bit more interesting:
- Span kind for "settle" could IMHO just be stated to be client by default: Span structure for messaging scenarios #220 (comment)
- Some confusion in wording re. process and consumer and producer tracer correlation: Span structure for messaging scenarios #220 (comment) and Span structure for messaging scenarios #220 (comment)
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
Co-authored-by: Christian Neumüller <christian+github@neumueller.me>
Co-authored-by: Christian Neumüller <christian+github@neumueller.me>
Co-authored-by: Christian Neumüller <christian+github@neumueller.me>
Co-authored-by: Christian Neumüller <christian+github@neumueller.me>
Co-authored-by: Christian Neumüller <christian+github@neumueller.me>
text/trace/0220-messaging-semantic-conventions-span-structure.md
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved, but for clarity, I suggest applying #220 (comment) and #220 (comment) or similar clarifications. ✅
…emetry#526) open-telemetry/oteps#220 recommends: > For each message it accounts for, the "Deliver" or "Receive" span SHOULD link to the message's creation context. In addition, if it is possible the creation context MAY be set as a parent of the "Deliver" or "Receive" span. But also acknolwedges: > open-telemetry/opentelemetry-specification#454 To instrument pull-based "Receive" operations as described in this document, it is necessary to add links to spans after those spans were created. The reason for this is, that not all messages are present at the start of a "Receive" operations, so links to related contexts cannot be added at the start of the span. Our "Receive" spans do not link to the message's creation context, and indeed it doesn't seem possible to do so. Likewise for setting the parent. This tries to do it anyway, and results in: - "Receive" span links remain unset; - "Receive" span is a root span for a new trace; - "Process" span trace_id is correctly set to the "Send" context; - "Process" span's parent is incorrectly set to "Send" instead of "Receive".
…emetry#526) open-telemetry/oteps#220 recommends: > For each message it accounts for, the "Deliver" or "Receive" span SHOULD link to the message's creation context. In addition, if it is possible the creation context MAY be set as a parent of the "Deliver" or "Receive" span. But also acknolwedges: > open-telemetry/opentelemetry-specification#454 To instrument pull-based "Receive" operations as described in this document, it is necessary to add links to spans after those spans were created. The reason for this is, that not all messages are present at the start of a "Receive" operations, so links to related contexts cannot be added at the start of the span. Our "Receive" spans do not link to the message's creation context, and indeed it doesn't seem possible to do so. Likewise for setting the parent. In lieu of a specification layer solution, this proposes adding a configuration flag so that users can opt-in to setting the "Send" context as parent for the "Process" span. This comes at the cost of a continuous trace including the "Send"-"Receive"-"Process" spans, with "Receive" orphaned from both "Send" and "Process". This doesn't attempt to reproduce the "none" `propagation_style` included in `sidekiq` instrumentation and other similar gems. If this is an interesting direction, we could consider implementing it.
This OTEP aims at defining consistent conventions about what spans to create for messaging scenarios, and at defining how those spans relate to each other. Instrumentors should be able to rely on a consistent set of conventions, as opposed to deducing conventions from a set of examples. This was split from OTEP open-telemetry#192, which became too comprehensive.
This OTEP aims at defining consistent conventions about what spans to create for messaging scenarios, and at defining how those spans relate to each other. Instrumentors should be able to rely on a consistent set of conventions, as opposed to deducing conventions from a set of examples. This was split from OTEP open-telemetry#192, which became too comprehensive.
This OTEP aims at defining consistent conventions about what spans to create for messaging scenarios, and at defining how those spans relate to each other. Instrumentors should be able to rely on a consistent set of conventions, as opposed to deducing conventions from a set of examples. This was split from OTEP open-telemetry#192, which became too comprehensive.
This OTEP aims at defining consistent conventions about what spans to create for messaging scenarios, and at defining how those spans relate to each other. Instrumentors should be able to rely on a consistent set of conventions, as opposed to deducing conventions from a set of examples. This was split from OTEP open-telemetry#192, which became too comprehensive.
This OTEP aims at defining consistent conventions about what spans to create for messaging scenarios, and at defining how those spans relate to each other. Instrumentors should be able to rely on a consistent set of conventions, as opposed to deducing conventions from a set of examples. This was split from OTEP open-telemetry#192, which became too comprehensive.
This OTEP aims at defining consistent conventions about what spans to create for messaging scenarios, and at defining how those spans relate to each other. Instrumentors should be able to rely on a consistent set of conventions, as opposed to deducing conventions from a set of examples. This was split from OTEP open-telemetry#192, which became too comprehensive.
This OTEP aims at defining consistent conventions about what spans to create for messaging scenarios, and at defining how those spans relate to each other. Instrumentors should be able to rely on a consistent set of conventions, as opposed to deducing conventions from a set of examples. This was split from OTEP #192, which became too comprehensive.
This OTEP aims at defining consistent conventions about what spans to create for messaging scenarios, and at defining how those spans relate to each other. Instrumentors should be able to rely on a consistent set of conventions, as opposed to deducing conventions from a set of examples.
This was split from OTEP open-telemetry/opentelemetry-specification#192, which became too comprehensive.
Fixes open-telemetry/opentelemetry-specification#1085.