update quic-go to v0.52.0
Tons of HTTP/3 changes in this release, first and foremost proper support for graceful shutdown on both client and server side: https://github.com/quic-go/quic-go/releases/tag/v0.52.0
Thanks! That's exciting!
I bet we'll need to update our code to be compatible. @WeidiDeng Do you have an idea of what we'll need to update to support graceful shutdowns the easy way now? (Sorry to ping, I'm just quite sick atm so I'm not very productive rn)
Nothing needs to be updated on the caddy side. h3 server graceful shutdown is already supported. h3 client's (only used in reverse proxy if enabled) handling of servers' shutdown doesn't expose any new control knobs. It's nice to have because it means less errors will be encountered if the backend server restarts, since requests are retries if it's safe to do so.
Yes that's correct! There were no API changes for graceful shutdown, so as long as you're calling Shutdown, everything should work as expected. On the server side, instead of just sending the GOAWAY frame (as we did earlier), we now also reset incoming streams.
And on the client side, the http3.Transport handles everything transparently. First and foremost, it doesn't send any more requests on the old connection after receiving the GOAWAY frame, but establishes a new connection.