-
Notifications
You must be signed in to change notification settings - Fork 99
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
Add net/http client instrumentor #91
Add net/http client instrumentor #91
Conversation
Hey @oxeye-gal, are you able to sign the CLA? |
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.
@oxeye-gal looks like this updates the test fixtures (which is expected since this is a new instrumentation) based on the CI failure
If you have kind installed, you should be able to run make fixture-nethttp
to re-generate the test output and commit the result.
Done. @damemi |
Sorry, need to run |
Hey @oxeye-gal - this PR needs rebasing after we merged ARM support in #82. I’m happy to help do that if you would like us to. |
Merge upstream main, add changelog and make small fixes
7878f9b
to
d59e91b
Compare
Hmm - not sure what happened there. I'll take a look when I can. |
@oxeye-gal now #92 has been merged, I’ll look to update this PR too 👍🏻 |
Picking this up now - sorry it's taken longer than expected to get back to. |
…mentation into http_client_instrumentation # Conflicts: # CHANGELOG.md # test/e2e/gin/traces.json # test/e2e/gorillamux/traces.json # test/e2e/nethttp/traces.json
Includes formatting the query to be multi line for easier reading
…trumentation into http_client_instrumentation # Conflicts: # CHANGELOG.md # Makefile
PR to update @oxeye-gal's PR is ready for merge, once it's done, we can review & merge this PR 🎉 |
Update upstream PR to add HTTP client propagation support
@oxeye-gal please could you "update branch" one more time, and we can merge this PR :) |
Requested changes have been made, I will be updating to consolidate probes once merged
@open-telemetry/go-instrumentation-approvers Please can you review this PR - it needs a final "update branch" but once done I'd like to merge this. I've worked on making sure it works and plan on expanding the same work to the other HTTP probes once it's done (see #101). |
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.
lgtm
Hi,
This PR attempts to add instrumentation for net/http client.
We do it by writing a fake tophash value (as calculating the correct one will be harder to achieve) to the first headers map bucket and writing the "traceparent" header key and value into memory.
This was tested with Go versions 1.12-1.19.
Our test environment consisted of instrumented Python application that sends a request to instrumented Go http server which in turn sends an http request to an additional instrumented Go http server.
The produced trace looks like the following:
We would love to get your feedback on this.
Thanks!