]> git.kaiwu.me - haproxy.git/commit
BUG/MEDIUM: quic: do not spin on the accept tasklet of a blocked listener
authorOlivier Houchard <ohouchard@haproxy.com>
Thu, 19 Nov 2026 17:08:33 +0000 (18:08 +0100)
committerOlivier Houchard <cognet@ci0.org>
Thu, 19 Nov 2026 17:27:40 +0000 (18:27 +0100)
commit5515125880b981adfc6934fc93b38c66bec9e5cc
treea02a1e6041b79cfc345d744335042c5ae84bcf42
parentf569d81646c47c851bb66a895f5160f3edbf69f5
BUG/MEDIUM: quic: do not spin on the accept tasklet of a blocked listener

Since commit 4377dbd75 ("BUG/MINOR: quic: Missing listener accept queue
tasklet wakeups") in 2.8-dev5, quic_accept_run() wakes itself up again as
long as connections remain in a listener's accept queue, so that those
beyond the maxaccept budget are accepted. But when the listener cannot
accept anymore, because it is full (bind maxconn) or limited (rate limit,
global maxconn), the tasklet runs in a loop and uses 100% of a thread
until the listener is resumed.

Let's only retry at once when the listener is still ready. Otherwise,
the accept tasklets of the threads with queued connections are woken up
when the listener is enabled again, and when it is unbound so that these
connections are refused.

This should be backported to all stable versions, with the previous
commit.

This was reported in GitHub issue #3578.
include/haproxy/quic_sock.h
src/proto_quic.c
src/quic_sock.c