Skip to content
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

empty spans are generated by auto-instrumentation #81

Closed
JamieDanielson opened this issue Apr 18, 2023 · 2 comments · Fixed by #86
Closed

empty spans are generated by auto-instrumentation #81

JamieDanielson opened this issue Apr 18, 2023 · 2 comments · Fixed by #86

Comments

@JamieDanielson
Copy link
Member

JamieDanielson commented Apr 18, 2023

I think this empty span is a bug in the auto-instrumentation, but that should be a separate issue to track instead of fix in this PR
Originally posted by @damemi in #46 (comment)

This was discussed during SIG meeting. The traces.json output being used for the e2e test shows the currently incorrect behavior of empty span IDs being generated with auto-instrumentation. This test should convert span IDs to "xxxxx" as seen in the top span, and the extra span appears to be a duplicate with no information.

I think I've traced this back to this PR #34 - specifically, keeping both function names for net/http instrumentation. If I adjust the code to only use "net/http.HandlerFunc.ServeHTTP" I don't have duplicated empty span IDs. Note I'm also working on some other changes that could also impact this so I might be off in the specific area causing this, but would be curious to try a test with this (the e2e tests were added after this change was made).

@damemi
Copy link
Contributor

damemi commented Apr 19, 2023

@JamieDanielson thanks for digging into this, if you have the change you think will fix it can you please open the PR? It would be interesting to see if the e2es catch the fix

@JamieDanielson
Copy link
Member Author

Some changes from #86 have been ported over to #82, including the change to keep one function name for ServeHTTP... and this has solved the issue of empty spans. #86 has been updated to specifically add back the scoped spans for gorilla/mux.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants