-
Notifications
You must be signed in to change notification settings - Fork 81
Description
Background
Starting from the definition about the "minimum" interaction:
At a minimum they MUST propagate the traceparent and tracestate headers and guarantee traces are not broken. This behavior is also referred to as forwarding a trace.
Let's assume we have the following scenario, where 3 services are call during a request A -> B -> C
(Service A
calls Service B
which calls Service C
), and assume that the owner of the Service B
wants tracing disable so they will do the "minimum" interaction defined above. With this it will look like Service A
-> Service C
(service A calls Service C, which is not really the reality).
Proposal
Add some information into the trace-flags about the fact that the request recently passed a Service that has not participated in the trace. For this we can define a "propagation-only-parent" flag bit, that has the following behavior:
- If a
Service
was doing the minimum propagation only before, they will set this bit to1
when they send the header to the next service to signal that the parent was a propagation only. - If a
Service
participates into the trace they will set this bit to0
to signal that the parent is not a propagation only.
How does this help?
Knowing that the parent participates or not into the trace is a critical information that can be used by the backend when showing parent child relationships and to inform the user about the correct connection between the services. In this case what the backend may do is just to inform the user that there are intermediate services that are not participating in the trace (backend cannot know about how many, what other services are doing since they decided to not participate in the trace).
Questions
- Do we need an extra bit to represent if the "propagation-only-parent" bit is set or not?