]> git.kaiwu.me - haproxy.git/commit
MINOR: filters: Maintain a global instance list per proxy
authorChristopher Faulet <cfaulet@haproxy.com>
Thu, 1 Oct 2026 05:26:21 +0000 (07:26 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Fri, 9 Oct 2026 14:17:35 +0000 (16:17 +0200)
commitac206a0ae5eb4489da3326a7483fcbba2e5c9554
tree0cc05ecd1fcd9baf21ae6bacc381b50b0f2a5e2f
parent3721b3b1c6e137cc061dd6a9e757a22170da7b95
MINOR: filters: Maintain a global instance list per proxy

Add FLT_SIDE_GLOBAL and a global ordering link to each filter instance.
Create px->conf.filter_refs in registry order alongside filter_req_refs and
filter_res_refs, and flatten these references into px->filter_instances.
Every instance belongs to the global order as well as its applicable
channels.

Use common ordering helpers for traversal, class references, flattening and
sequence moves. Initialize all instance links on allocation, and unlink both
channel trees before releasing instances through the global owner list.
Initialize directive links before fallible parsing/copying operations.  Roll
back a sequence move that creates a cycle so subsequent lookups and cleanup
retain reachable, loop-free trees.

The global list is maintained here, but side-independent startup operations
still traverse request/response orders until the next patch. The parser and
CLI do not expose global sequencing or inspection yet.
include/haproxy/filters-t.h
include/haproxy/proxy-t.h
src/filters.c
src/proxy.c