Mercurial > hg > nginx
diff src/event/quic/ngx_event_quic.h @ 9055:1192923be0aa quic
QUIC: idle mode for main connection.
Now main QUIC connection for HTTP/3 always has c->idle flag set. This allows
the connection to receive worker shutdown notification. It is passed to
application level via a new conf->shutdown() callback.
The HTTP/3 shutdown callback sends GOAWAY to client and gracefully shuts down
the QUIC connection.
author | Roman Arutyunyan <arut@nginx.com> |
---|---|
date | Wed, 19 Oct 2022 17:45:18 +0400 |
parents | 2e51cf3ffd90 |
children | b0c2234aaa9f |
line wrap: on
line diff
--- a/src/event/quic/ngx_event_quic.h Wed Oct 19 17:45:30 2022 +0400 +++ b/src/event/quic/ngx_event_quic.h Wed Oct 19 17:45:18 2022 +0400 @@ -28,6 +28,9 @@ #define NGX_QUIC_STREAM_UNIDIRECTIONAL 0x02 +typedef void (*ngx_quic_shutdown_pt)(ngx_connection_t *c); + + typedef enum { NGX_QUIC_STREAM_SEND_READY = 0, NGX_QUIC_STREAM_SEND_SEND, @@ -74,6 +77,8 @@ ngx_int_t stream_reject_code_uni; ngx_int_t stream_reject_code_bidi; + ngx_quic_shutdown_pt shutdown; + u_char av_token_key[NGX_QUIC_AV_KEY_LEN]; u_char sr_token_key[NGX_QUIC_SR_KEY_LEN]; } ngx_quic_conf_t;