]> git.kaiwu.me - haproxy.git/commit
MINOR: server: set maintenance mode on "purge server"
authorAmaury Denoyelle <adenoyelle@haproxy.com>
Mon, 21 Sep 2026 08:36:36 +0000 (10:36 +0200)
committerAmaury Denoyelle <adenoyelle@haproxy.com>
Wed, 14 Oct 2026 09:33:40 +0000 (11:33 +0200)
commita5adffde2c174e5e4d7437f5e0ee43361c3701b4
tree79b6c956dff05bc352e5931c616d58946927a59f
parent410719abdc07650a0fc5692a457cf998754715b9
MINOR: server: set maintenance mode on "purge server"

This patch changes behavior of "purge server" to automatically set a
server in maintenance mode if needed. This is not performed if a server
cannot be removed due to a configuration limitation.

The objective is to improve the user API. While not a big change in the
context of a single "purge server", automatic maintenance mode will
become a must have for the future "purge all servers". Thus, this change
allow guaranteeing a similar behavior between these two commands.

To implement it, a new argument is added to srv_check_for_deletion(),
indicating the deletion mode. For better code clarity, this is defined
as an enum type pr_del_mode.
doc/management.txt
include/haproxy/proxy-t.h
include/haproxy/server.h
src/cli.c
src/server.c