5 ms·
It's interesting that http2 server push is not supported. Any reason why? Server push is a weird feature but very useful and popular.
by ejcx 10y ago
It's interesting that http2 server push is not supported. Any reason why? Server push is a weird feature but very useful and popular.
- mholt 10y agoTurns out it's extremely difficult to implement correctly and in a truly optimized fashion. Lots of variables. Do it wrong and you can hurt performance instead of help it.
- ejcx 10y agoWith caddy, do you get this functionality for free through the go std packages?
- xfalcox 10y agoI couldn't get caddy to push resources when using it as a reverse proxy. Any ideas?
- mholt 10y agoWell, Caddy doesn't even support push until the next release. But even then, the Go standard lib will have to proxy push frames through. We could look into a contribution to Go or a workaround when we or a contributor has time.
- mholt 10y agoThe next release of Caddy will support push, yes. But you'll have to configure it (for now - until we can figure out a good way to do it correctly, automatically).
- chucke 10y agoAlthough correct use of the feature is still debatable, interoperability with CDNs is not. The link header standard is the de-facto way to communicate with frontends about what to push.
- throwasehasdwi 10y agoProbably because it requires sockets to be kept open. Makes it a lot easier to DDOS the server (because you need to maintain HTTP + TCP state), especially at CDN traffic levels. Too bad IPV4 NAT has made open ports on client machines nearly impossible, otherwise maintaining this connection would not be required.
- deleted 10y ago[deleted]
- chucke 10y ago> Probably because it requires sockets to be kept open. HTTP2 requires kept-open sockets, not server push. HTTP1.1 already supports keep-alive sockets btw, and CDNs have survived that DDoS attack :)
- darkhorn 10y agoMicrosoft provides best user experience /s