mirror of
https://github.com/caddyserver/caddy.git
synced 2026-06-07 06:25:24 -04:00
httpserver: Add experimental H2C support (#3289)
* reverse_proxy: Initial attempt at H2C transport/client support (#3218) I have not tested this yet * Experimentally enabling H2C server support (closes #3227) See also #3218 I have not tested this * reverseproxy: Clean up H2C transport a bit * caddyhttp: Update godoc for h2c server; clarify experimental status * caddyhttp: Fix trailers when recording responses (fixes #3236) * caddyhttp: Tweak h2c config settings and docs
This commit is contained in:
@@ -111,6 +111,17 @@ type Server struct {
|
||||
// This field is not subject to compatibility promises.
|
||||
ExperimentalHTTP3 bool `json:"experimental_http3,omitempty"`
|
||||
|
||||
// Enables H2C ("Cleartext HTTP/2" or "H2 over TCP") support,
|
||||
// which will serve HTTP/2 over plaintext TCP connections if
|
||||
// a client support it. Because this is not implemented by the
|
||||
// Go standard library, using H2C is incompatible with most
|
||||
// of the other options for this server. Do not enable this
|
||||
// only to achieve maximum client compatibility. In practice,
|
||||
// very few clients implement H2C, and even fewer require it.
|
||||
// This setting applies only to unencrypted HTTP listeners.
|
||||
// ⚠️ Experimental feature; subject to change or removal.
|
||||
AllowH2C bool `json:"allow_h2c,omitempty"`
|
||||
|
||||
primaryHandlerChain Handler
|
||||
errorHandlerChain Handler
|
||||
listenerWrappers []caddy.ListenerWrapper
|
||||
|
||||
Reference in New Issue
Block a user