Skip to content

HTTP2 and HTTP1 on the same socket #44887

@FStefanni

Description

@FStefanni

What is the problem this feature will solve?

Support both HTTP1 and HTTP2 on the same server socket.

I have seen the discussion on #26795, but the issue was closed without a clear answer (for what I was able to understand).
As some of the commenters pointed out:

  • It is not an uncommon feature/need, since IoT and embedded devices could need it. And more in general, not all network traffic and server applications are related to browsers, so this feature would be very useful.
  • It is useful on case of reverse proxies, since it is very common to let them handle the TLS termination, and just forward plain HTTP to the actual services.
  • It simplifies and generalizes node.js projects, since servers could just create HTTP2 sockets, being always able to support both versions

What is the feature you are proposing to solve the problem?

Add a "allowHTTP1": true, option to HTTP2 non-TLS server, similar to the one available for HTTP2 TLS server.

What alternatives have you considered?

I don't see many alternatives actually...

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.http2Issues or PRs related to the http2 subsystem.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions