-
Notifications
You must be signed in to change notification settings - Fork 795
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
Nested Child spans are not getting parented correctly #1940
Comments
I am getting 12
|
Seems something is wrong with our imports here. Looks like you use can you reproduce this by using plain JavaScript or Typescript? |
I am using Babel https://github.com/mnadeem/nodejs-opentelemetry-tempo/blob/main/package.json I don't have project setup for typescript, further I would have to learn Typescript |
I never used babel so can't help here. But I think instead |
What about |
I am not getting exception now, however nested span is not working now as well. Note: the version is 0.15.0 |
Following does not give any error, however same result as above
|
Here is the output of consoleexporter
|
in your last sample the implementation of |
Thanks a bundle @Flarna It is working like a charm now |
Any help on Approach # 2 , utilizing context.with doSomeWorkInNewNestedSpan should be parent of doSomeWorkInNewNested2Span
That is not the care write now |
Try |
Thanks a bundle @Flarna Working like a charm now. https://github.com/mnadeem/nodejs-opentelemetry-tempo This would be helpful for folks understanding Opentelemetry and using BabelJs and Grafana Tempo |
We are discussing/working on a convenience API for this that will make this I am also working on a new documentation which should simplify these common use cases. |
FWIW I'm a Node.js programmer of 10 years, spent an hour reading this thread and many others + docs, and still cant figure out how to do something as simple (or should be simple) as making a child span link properly to parent. |
Any progress on this? Literally same here, some working code-snipped would help |
What's wrong with this sample? |
That is actually what I was looking for (and have basically since implemented). Most of the examples I was seeing relied on the use of |
Takeaway here I guess is to add documentation to the website |
Opened a follow-up documentation task. Closing this as there is no bug. Please feel free to reopen or comment if you disagree. |
Please answer these questions before submitting a bug report.
What version of OpenTelemetry are you using? 0.15.0
What version of Node are you using? v14.15.5
Please provide the code you used to setup the OpenTelemetry SDK : https://github.com/mnadeem/nodejs-opentelemetry-tempo
What did you do? Created Child Spans
If possible, provide a recipe for reproducing the error.: Follow the guidelines in https://github.com/mnadeem/nodejs-opentelemetry-tempo
What did you expect to see? Nested Child spans should be parented correctly
Something like this nested and stair cased (from https://github.com/mnadeem/boot-opentelemetry-tempo)
What did you see instead? Nested child spans are not parented correctly
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: