MINOR: server: move actconns to the per-thread structure
authorWilly Tarreau <w@1wt.eu>
Thu, 4 Mar 2021 09:47:54 +0000 (10:47 +0100)
committerWilly Tarreau <w@1wt.eu>
Fri, 5 Mar 2021 14:00:24 +0000 (15:00 +0100)
commitd4e78d873cecf9938885c90e736f8b761a35fb55
tree4760e4fd30072c744c00a76a1ab3912d3ac6d7f8
parent430bf4a483bdd8257a63bc3ac88367006322f80d
MINOR: server: move actconns to the per-thread structure

The actconns list creates massive contention on low server counts because
it's in fact a list of streams using a server, all threads compete on the
list's head and it's still possible to see some watchdog panics on 48
threads under extreme contention with 47 threads trying to add and one
thread trying to delete.

Moving this list per thread is trivial because it's only used by
srv_shutdown_streams(), which simply required to iterate over the list.

The field was renamed to "streams" as it's really a list of streams
rather than a list of connections.
include/haproxy/server-t.h
include/haproxy/stream.h
src/cfgparse.c
src/hlua.c
src/server.c