Skip to content

http: deal with the lack of http proxy support in node.js core. #15620

Closed
@martinheidegger

Description

@martinheidegger

This is a follow-up on #8381.

Summary:
Node's http module does not support http proxies by default. This is a unfortunate situation as libraries don't use packages for http that support http proxies and as a result quite a few tools in the Node ecosystem lack the support for http proxies (i.e. through environment variables).

It would be helpful if Node.js could support user proxies and if someone could take the time to implement it, I think the following plan could help get us there:

  1. Old versions of Node.js will never gain http proxy support so it would be important to have a recommended way how to add proxy support to user-land libraries to work on the old versions of Node.js. A guide on "how to support proxies" (maybe combined with a package) seems like a minimum requirement to fix this issue which will help no matter how this topic progresses. (Anyone can start with this, no need to wait for approval, help dearly welcome).
  2. Create a PR to the Node.js docs in which it clearly explains that proxies are the responsibility of user-land and reference the recommended implementation/article in 1. (Just reflecting the current state of affairs)
  3. Create a new discussion on to how the package used in 1. could become part of Node.js core in order to reduce the implementation cost for current and new packages.
  4. Discuss the possibility of creating a Node flag that enables the behavior of 3. in case someone is stuck with user-land code that doesn't implement proxies.

Metadata

Metadata

Assignees

No one assigned

    Labels

    feature requestIssues that request new features to be added to Node.js.httpIssues or PRs related to the http subsystem.stale

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions