]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MINOR: peers: Report a resync was explicitly requested from a thread-safe manner
authorChristopher Faulet <cfaulet@haproxy.com>
Fri, 22 Mar 2024 15:27:13 +0000 (16:27 +0100)
committerChristopher Faulet <cfaulet@haproxy.com>
Tue, 16 Apr 2024 08:29:21 +0000 (10:29 +0200)
commitef066fa1867a493ef224cf4a18bed54775d4cd29
treef4fca1a06be1afe568c09cf011d54c721c0c0520
parentbdf16348837f42a15e7489900cb6d019a55615fb
BUG/MINOR: peers: Report a resync was explicitly requested from a thread-safe manner

Flags on the peers section state must be updated from a thread-safe manner.
It is not true today. With this patch we take care PEERS_F_RESYNC_REQUESTED
flag is only set by the resync task. To do so, a peer flag is used. This
flag is only set once and never removed. It is juste used for debugging
purpose. So it is enough to set it on a peer and be sure to report it on the
peers section when the sync task is executed.

This patch relies on previous ones:

 * MINOR: peers: Add functions to commit peer changes from the resync task
 * MINOR: peers: sligthly adapt part processing the stopping signal
 * MINOR: peers: Add flags to report the peer state to the resync task
 * MINOR: peers: Add 2 peer flags about the peer learn status
 * MINOR: peers: Split resync process function to separate running/stopping states
src/peers.c