]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MEDIUM: spoe: Be sure to create a SPOE applet if none on the current thread
authorChristopher Faulet <cfaulet@haproxy.com>
Tue, 9 Jul 2024 06:24:05 +0000 (08:24 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Wed, 10 Jul 2024 08:52:20 +0000 (10:52 +0200)
commit5e84f13a0b3b915990a4e25ec9448fdbef3c1a14
tree7920d45d66bea6c44e85fd79dae79626b111f0d4
parent4a2dd6f3777959187565edd79475091e155e2161
BUG/MEDIUM: spoe: Be sure to create a SPOE applet if none on the current thread

When a message is queued, waiting to be processed by a SPOE applet, there
are some heuristic to know if a new applet must be created or not. There are
2 conditions to skip the applet creation:

  1 - if there are enough idle applets on the current thread, or,

  2 - if the processing rate on the current thread is high enough to handle
      this new message

In the 2nd case, there is a flaw when the number of processed messages falls
to zero while the processing rate is still greater than zero. In that case,
we will skip the SPOE applet creation without taking care to check there is
at least one applet on the current thread.

So now, the conditions above to skip the SPOE applet creation are only
evaluated if there is at least one applet on the current thread.

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