MEDIUM: proxy: make soft_stop() stop most listeners using protocol_stop_now()
authorWilly Tarreau <w@1wt.eu>
Wed, 7 Oct 2020 14:52:43 +0000 (16:52 +0200)
committerWilly Tarreau <w@1wt.eu>
Fri, 9 Oct 2020 16:29:04 +0000 (18:29 +0200)
commit626f3a7beb33f921b7b13fda4d1d585160fe2051
treef1f270950118a62454baacd4b0fea50797c85670
parent02e8557e8812892ee61218797b61e3e60cb2764c
MEDIUM: proxy: make soft_stop() stop most listeners using protocol_stop_now()

One difficulty in soft-stopping is to make sure not to forget unlisted
listeners. By first doing a pass using protocol_stop_now() we catch the
vast majority of them. The few remaining ones are the ones belonging to
a proxy having a grace period. For these ones, the proxy will arm its
stop_time timer and emit a log message.

Since neither UDP listeners nor peers use the grace period, we can already
get rid of the special cases there since we know they will have been stopped
by the protocols.
src/proxy.c