honeycombio / libhoney-js

Javascript library for sending data to Honeycomb
Apache License 2.0
49 stars 28 forks source link

fix: replace superagent-proxy with direct use of proxy-agent #389

Closed robbkidd closed 11 months ago

robbkidd commented 1 year ago

Which problem is this PR solving?

Short description of the changes

This is the equivalent behavior of the previous agent configuration. If a proxy URL is provided in libhoney config, a single ProxyAgent will be created with that proxy URL set for all connections. No nuanced lookup of proxy config from the environment based on target URL protocol.

proxy-agent is a hefty import, but we were importing an early edition of it (v5.0.0) already via superagent-proxy. Update: whew, bundlephobia really doesn't handle direct links well.

TODO?

kyle-watershed commented 11 months ago

@robbkidd thanks for putting up this fix! any movement on this? I'd like to use libhoney-js with the fix as soon as this is merged and released