Skip to content
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

net/http: move HTTP/2 into std #67810

Open
3 of 8 tasks
neild opened this issue Jun 4, 2024 · 0 comments
Open
3 of 8 tasks

net/http: move HTTP/2 into std #67810

neild opened this issue Jun 4, 2024 · 0 comments
Labels
NeedsFix The path to resolution is known, but the work has not been done.
Milestone

Comments

@neild
Copy link
Contributor

neild commented Jun 4, 2024

The net/http package includes transparent support for HTTP/2. The source of truth for this implementation is the golang.org/x/net/http2 package, which is vendored into std (using a rather complicated process to avoid import cycles). The http2 package also exposes a number of configuration settings and features which are not directly accessible from net/http.

There were good reasons for starting development of the HTTP/2 implementation outside of std, but the current state of affairs is confusing and inconvenient. Backporting HTTP/2 fixes into minor releases is difficult. New versions of net/http need to support old versions of x/net. We can't make changes to the HTTP/1 and HTTP/2 implementations atomically. Users need to import an x/ package to configure HTTP/2 settings.

This issue is a tracking issue for moving HTTP/2 into std.

The desired end state is that the canonical HTTP/2 implementation used by net/http is located in the main Go repository and golang.org/x/net/http2 is deprecated.

The golang.org/x/net/http2 package has a substantial API surface. Some of that functionality (such as server and client configuration settings) will be made available via net/http, some will move into new packages, and some will be deprecated. The first stage of this project is to make every non-deprecated feature of golang.org/x/net/http2 available elsewhere.

(Original discussion: #60746)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
NeedsFix The path to resolution is known, but the work has not been done.
Projects
None yet
Development

No branches or pull requests

2 participants