axum-server
axum-server copied to clipboard
[breaking change] Implement HTTP/1/2-only support
This PR changes dependencies to be more careful about the default features enabled. Now HTTP/1 and HTTP/2 are enabled by default but can be disabled if so desired. There is also now a way to set the server to only enable one of the two protocols.
This would re-open #80 and I have no clue how to solve that without a major redesign of the public API.
The only easier way that comes to mind is cloning the ServerConfig and then modifying the ALPN if it doesn't match while handling the Acceptor.
I will leave this open until the next version upgrade.