]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MINOR: server/event_hdl: add support for SERVER_UP and SERVER_DOWN events
authorAurelien DARRAGON <adarragon@haproxy.com>
Fri, 25 Nov 2022 17:07:49 +0000 (18:07 +0100)
committerChristopher Faulet <cfaulet@haproxy.com>
Tue, 6 Dec 2022 09:22:07 +0000 (10:22 +0100)
commit22f82f81e522fd6ba2cd0512fe4d7ed72b49edde
treed9a2fe78fe02bd585d8eb2116ddfdf77ca54029a
parent129ecf441f9be70ff3e39fd3b84964e0c4bf2718
MINOR: server/event_hdl: add support for SERVER_UP and SERVER_DOWN events

We're using srv_update_status() as the only event source or UP/DOWN server
events in an attempt to simplify the support for these 2 events.

It seems srv_update_status() is the common path for server state changes anyway

Tested with server state updated from various sources:
  - the cli
  - server-state file (maybe we could disable this or at least don't publish
  in global event queue in the future if it ends in slower startup for setups
  relying on huge server state files)
  - dns records (ie: srv template)
  (again, could be fined tuned to only publish in server specific subscriber
  list and no longer in global subscription list if mass dns update tend to
  slow down srv_update_status())
  - normal checks and observe checks (HCHK_STATUS_HANA)
  (same as above, if checks related state update storms are expected)
  - lua scripts
  - html stats page (admin mode)
include/haproxy/event_hdl-t.h
include/haproxy/server-t.h
src/event_hdl.c
src/server.c