Skip to content

actix-web can't use http2 and http1 simultaneously by listening same address without using https #2943

Answered by robjtede
rootBiao asked this question in Ideas
Discussion options

You must be logged in to vote

Update, support for this was added in actix-http v3.3: https://docs.rs/actix-http/latest/actix_http/struct.HttpService.html#method.tcp_auto_h2c

This is true. Without some form of protocol negotiation like that this is provided by TLS ALPN then we cannot select an appropriate HTTP version to use. Inspecting bytes is possible but would be unnecessary overhead for all Actix Web servers. I do know it is possible to do at the user level but would need to dig up the code to make it work.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by robjtede
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Ideas
Labels
None yet
2 participants