-
Notifications
You must be signed in to change notification settings - Fork 224
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
Fix #1770 support for proxies in destination context #2126
Conversation
💚 Build Succeeded
Expand to view the summary
Build stats
Test stats 🧪
Trends 🧪 |
@ebuildy Thanks. The best original discussion of this is here: Qard/http-request-to-url#1 |
jenkins run the tests |
I'm not clear on the history of commits here. Is this proxy functionality something we missed in #2039 where the 'http-request-to-url' dep was removed? |
There is an old bug in case we use HTTP proxy to send query, the URL from
|
jenkins run the tests please |
Additional Context: We had hoped/assumed that removing the dependency on |
Wonderful! It looks like a bug from nodeJS it-self actually, there is no way to guess if a https://github.com/nodejs/node/blob/master/lib/_http_client.js ClientRequest is using a proxy or not. |
@elasticmachine, run elasticsearch-ci/docs |
It looks like our CI is happy with things. Per @trentm's comments above
I've written up a test that captures the intent of this fix, based on the @ebuildy -- would you be able to
With those in place we should be able to merge. |
Copy/paste from Qard/http-request-to-url@7406c37 fix linter add tests
jenkins run the tests please |
@elasticmachine, run elasticsearch-ci/docs |
@ebuildy Apologies -- it looks like there's a timing issue in the test I handed you (only pops up in Node 8.6). I made a PR to your branch to fix that. https://github.com/ebuildy/apm-agent-nodejs/pull/1/files |
fix: timing issue with tests
Ok got it! thanks you. (Sorry for the delay, I am in France ....) |
@ebuildy No rush intended or asked for :) Also -- PR to fix the above linting errors: https://github.com/ebuildy/apm-agent-nodejs/pull/2 |
sure! just saying that because I answer always a day after. Thanks you for the fix |
jenkins run the tests please |
@elasticmachine, run elasticsearch-ci/docs |
jenkins run the tests please |
@elasticmachine, run elasticsearch-ci/docs |
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.
👍 does the thing, approving and merging
…2126) * Fix elastic#1770 support for proxies in destination context Fix for elastic#1770, ensures only a single url is set
Fix #1770 issue:
If a proxy is used, the destination context will not be set on outgoing http spans because the URL cannot be successfully extracted from the request.
Copy/paste from Qard/http-request-to-url@7406c37
Checklist