Why is SSL necessary for HTTP2? The protocol doesn...
# ktor
c
Why is SSL necessary for HTTP2? The protocol doesn't need it. I have a proxy before the server, but I can't use HTTP2 because Ktor doesn't know about it.
e
https://http2.github.io/faq/#does-http2-require-encryption in theory the spec doesn't mandate encryption, but in practice almost every other implementation of H2 requires it so if you don't have it you're not interoperable
c
I do have it, I just said so. The proxy handles it.
t
Out of curiosity, are the benefits worth it? A while ago, I remember thinking it would speed things up before reading posts like this https://mailman.nginx.org/pipermail/nginx/2015-December/049445.html
e
doing HTTP/2 server push is a bit tricky (or at least requires some additional coordination between the backend and the proxy) using HTTP/1.1 as the intermediate transport, but that's pretty much a dead feature now
(tl;dr I don't think there's a benefit to it either)
c
Any news on HTTP3? The latency is much lower
e
better for clients, but it doesn't make that much difference internally since the proxy can just keep a pool of warm connections to the backends
c
Only if the server is using HTTP2+, right?
HTTP1 requires a new handshake etc for each request, doesn't it?
e
no, keepalive is supported in HTTP/1.1 and doesn't have all the same downsides internally as it does when facing the public
and is used by https://www.nginx.com/blog/http-keepalives-and-web-performance/#Use-NGINX-as-an-Accelerating-HTTP-Proxy for example
NGINX then proxies the requests to the upstream server, using a local pool of keepalive connections.
593 Views