]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MINOR: peers: Add flags to report the peer state to the resync task
authorChristopher Faulet <cfaulet@haproxy.com>
Fri, 22 Mar 2024 13:34:21 +0000 (14:34 +0100)
committerChristopher Faulet <cfaulet@haproxy.com>
Tue, 16 Apr 2024 08:29:21 +0000 (10:29 +0200)
commit4ca8a0095513c070e3b32ca950cc1a39443de295
tree8fc24d7f80f3b88708c06120c18fd324675e7d39
parent9b78e33837917562544b308e818f7df3db8cac06
MINOR: peers: Add flags to report the peer state to the resync task

As the previous patch, this patch is also part of the refactoring of peer
locking mechanisme. Here we add flags to represent a transitional state for
a peer. It will be the resync task responsibility to update the peers state
accordingly.

A peer may be in 4 transitional states:

  * accepted : a connection was accepted from a peer
  * connected: a connection to a peer was established
  * release  : a peer session was released
  * renewed  : a peer session was released because it was replaced by a new
               one. Concretly, this will be equivalent to released+accepted

If none of these flags is set, it means the transition, if any, was
processed by the resync task, or no transition happened.
src/peers.c