Welcome! Log In Create A New Profile

Advanced

[PATCH 3 of 6] QUIC: call shutdown() callback only after handshake completion

Roman Arutyunyan
September 14, 2023 06:18AM
# HG changeset patch
# User Roman Arutyunyan <arut@nginx.com>
# Date 1694613709 -14400
# Wed Sep 13 18:01:49 2023 +0400
# Node ID 51166a8f35ba880415ddc2bf2745012a8d4cea34
# Parent 6d3ca6f8db357a1db267978f730875e51e87c608
QUIC: call shutdown() callback only after handshake completion.

Previously the callback could be called while QUIC handshake was in progress
and, what's more important, before the init() callback. Now it's postponed
after init().

This change is a preparation to postponing HTTP/3 session creation to init().

diff --git a/src/event/quic/ngx_event_quic.c b/src/event/quic/ngx_event_quic.c
--- a/src/event/quic/ngx_event_quic.c
+++ b/src/event/quic/ngx_event_quic.c
@@ -427,7 +427,7 @@ ngx_quic_input_handler(ngx_event_t *rev)
return;
}

- if (!qc->closing && qc->conf->shutdown) {
+ if (!qc->closing && qc->streams.initialized && qc->conf->shutdown) {
qc->conf->shutdown(c);
}

diff --git a/src/event/quic/ngx_event_quic_streams.c b/src/event/quic/ngx_event_quic_streams.c
--- a/src/event/quic/ngx_event_quic_streams.c
+++ b/src/event/quic/ngx_event_quic_streams.c
@@ -620,6 +620,10 @@ ngx_quic_do_init_streams(ngx_connection_
}
}

+ if (ngx_exiting && qc->conf->shutdown) {
+ qc->conf->shutdown(c);
+ }
+
for (q = ngx_queue_head(&qc->streams.uninitialized);
q != ngx_queue_sentinel(&qc->streams.uninitialized);
q = ngx_queue_next(q))
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
https://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

[PATCH 0 of 3] QUIC module compatibility issues

Roman Arutyunyan 443 September 11, 2023 07:32AM

[PATCH 1 of 3] QUIC: "handshake_timeout" configuration parameter

Roman Arutyunyan 118 September 11, 2023 07:32AM

Re: [PATCH 1 of 3] QUIC: "handshake_timeout" configuration parameter

Sergey Kandaurov 119 September 12, 2023 09:06AM

Re: [PATCH 1 of 3] QUIC: "handshake_timeout" configuration parameter

Roman Arutyunyan 122 September 13, 2023 11:56AM

[PATCH 2 of 3] HTTP/3: eliminated v3_session field from ngx_http_connection_t

Roman Arutyunyan 130 September 11, 2023 07:32AM

Re: [PATCH 2 of 3] HTTP/3: eliminated v3_session field from ngx_http_connection_t

Sergey Kandaurov 131 September 12, 2023 09:06AM

Re: [PATCH 2 of 3] HTTP/3: eliminated v3_session field from ngx_http_connection_t

Roman Arutyunyan 121 September 13, 2023 12:04PM

[PATCH 3 of 3] Modules compatibility: added QUIC to signature (ticket #2539)

Roman Arutyunyan 119 September 11, 2023 07:32AM

Re: [PATCH 3 of 3] Modules compatibility: added QUIC to signature (ticket #2539)

Sergey Kandaurov 138 September 12, 2023 09:06AM

Re: [PATCH 3 of 3] Modules compatibility: added QUIC to signature (ticket #2539)

Roman Arutyunyan 125 September 13, 2023 12:08PM

[PATCH 0 of 6] QUIC module compatibility issues

Roman Arutyunyan 157 September 14, 2023 06:18AM

[PATCH 1 of 6] QUIC: "handshake_timeout" configuration parameter

Roman Arutyunyan 155 September 14, 2023 06:18AM

[PATCH 2 of 6] HTTP/3: moved variable initialization

Roman Arutyunyan 132 September 14, 2023 06:18AM

[PATCH 3 of 6] QUIC: call shutdown() callback only after handshake completion

Roman Arutyunyan 124 September 14, 2023 06:18AM

Re: [PATCH 3 of 6] QUIC: call shutdown() callback only after handshake completion

Sergey Kandaurov 123 September 19, 2023 06:00AM

Re: [PATCH 3 of 6] QUIC: call shutdown() callback only after handshake completion

Sergey Kandaurov 151 September 19, 2023 06:34AM

Re: [PATCH 3 of 6] QUIC: call shutdown() callback only after handshake completion

Roman Arutyunyan 125 September 21, 2023 11:42AM

Re: [PATCH 3 of 6] QUIC: call shutdown() callback only after handshake completion

Sergey Kandaurov 137 September 22, 2023 07:24AM

[PATCH 4 of 6] HTTP/3: postponed session creation to init() callback

Roman Arutyunyan 124 September 14, 2023 06:18AM

[PATCH 5 of 6] QUIC: simplified setting close timer when closing connection

Roman Arutyunyan 125 September 14, 2023 06:18AM

[PATCH 6 of 6] Modules compatibility: added QUIC to signature (ticket #2539)

Roman Arutyunyan 116 September 14, 2023 06:18AM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 146
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 500 on July 15, 2024
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready