Mock spans. Span through several services #2121
Unanswered
senyacherenkov
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hey! I have a problem with tracing among microservices. Please, help! My case is next:
First service receives http-request. At this point I want to start root span for whole chain of handling and local span for local handling.
Then parsed data should go to another service. From that service data should come to first service, where I started span. And at every data handling I want to start span which measures local handling of this data. So, briefly, I need root span with 3 little spans. Root span shows whole duration of data handling.
I don't understand how to do so. My suggestion was to make mock root span. It means that I could create traceparent with start time, put that info into json and pass through described chain. And in the last service this mock span becomes real with startSpan() invoke. But as the result I got wrong sequence of spans. I've read docks and found info about links. It seems legit, but I found links under "TODO" mark in /opentelemetry-cpp/api/include/opentelemetry/trace/span_startoptions.h
/ TODO: // SpanContext remote_parent; // Links
Can I get picture like this in current version of Opentelemetry?
Right now I have picture like this:
P.s.: sorry for lame in pictures
Beta Was this translation helpful? Give feedback.
All reactions