]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MEDIUM: spoe: Never create new spoe applet if there is no server up
authorChristopher Faulet <cfaulet@haproxy.com>
Fri, 5 Jan 2024 16:06:48 +0000 (17:06 +0100)
committerChristopher Faulet <cfaulet@haproxy.com>
Fri, 5 Jan 2024 16:28:50 +0000 (17:28 +0100)
commit72c23bd4cd3ee3a79955fbdd601206a9fa7d19eb
tree35a784a1877ac1ced32f4b98e0ae2e68e474825b
parent7cc41514226a2072b538c859cd83dc01de0aeb3f
BUG/MEDIUM: spoe: Never create new spoe applet if there is no server up

This test was already performed when a new message is queued into the
sending queue. However not when the last applet is released, in
spoe_release_appctx(). It is a quite old bug. It was introduced by commit
6f1296b5c7 ("BUG/MEDIUM: spoe: Create a SPOE applet if necessary when the
last one is released").

Because of this bug, new SPOE applets may be created and quickly released
because there is no server up, in loop and while there is at least one
message in the sending queue, consuming all the CPU. It is pretty visible if
the processing timeout is high.

To fix the bug, conditions to create or not a SPOE applet are now
centralized in spoe_create_appctx(). The test about the max connections per
second and about number of active servers are moved in this function.

This patch must be backported to all stable versions.
src/flt_spoe.c