MINOR: proxy: Introduce proxy flags to replace disabled bitfield
authorChristopher Faulet <cfaulet@haproxy.com>
Wed, 6 Oct 2021 12:24:19 +0000 (14:24 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Fri, 15 Oct 2021 12:12:19 +0000 (14:12 +0200)
commitdfd10ab5ee023a9d67ec159752249f24f5177f93
tree824e89f292b48d19e32fae78fd495efb7659f774
parent647a61cc4b167bc394a38f7f3fa7d2a176b90729
MINOR: proxy: Introduce proxy flags to replace disabled bitfield

This change is required to support TCP/HTTP rules in defaults sections. The
'disabled' bitfield in the proxy structure, used to know if a proxy is
disabled or stopped, is replaced a generic bitfield named 'flags'.

PR_DISABLED and PR_STOPPED flags are renamed to PR_FL_DISABLED and
PR_FL_STOPPED respectively. In addition, everywhere there is a test to know
if a proxy is disabled or stopped, there is now a bitwise AND operation on
PR_FL_DISABLED and/or PR_FL_STOPPED flags.
19 files changed:
addons/promex/service-prometheus.c
include/haproxy/backend.h
include/haproxy/proxy-t.h
src/cfgparse-listen.c
src/cfgparse.c
src/check.c
src/extcheck.c
src/filters.c
src/haproxy.c
src/mux_fcgi.c
src/mux_h1.c
src/mux_h2.c
src/mworker.c
src/proxy.c
src/server.c
src/server_state.c
src/stats.c
src/stick_table.c
src/stream.c