MEDIUM: config: mark "grace" as deprecated

This was introduced 15 years ago or so to delay the stopping of some
services so that a monitoring device could detect its port being down
before services were stopped. Since then, clean reloads were implemented
and this doesn't cope well with reload at all, preventing the new process
from seamlessly binding, and forcing processes to coexist with half-baked
configurations.

Now it has become a real problem because there's a significant code
portion in the proxies that is solely dedicated to this obsolete feature,
and dealing with its special cases eases the introduction of bugs in
other places so it's about time that it goes.

We could tentatively schedule its removal for 2.4 with a hard deadline
for 2.5 in any case.
This commit is contained in:
Willy Tarreau 2020-10-09 19:07:01 +02:00
parent e03204c8e1
commit ab0a5192a8
2 changed files with 4 additions and 1 deletions

View File

@ -4498,7 +4498,7 @@ fullconn <conns>
See also : "maxconn", "server"
grace <time>
grace <time> (deprecated)
Maintain a proxy operational for some time after a soft stop
May be used in sections : defaults | frontend | listen | backend
yes | yes | yes | yes

View File

@ -2602,6 +2602,9 @@ int cfg_parse_listen(const char *file, int linenum, char **args, int kwm)
curproxy->grace = val;
if (alertif_too_many_args(1, file, linenum, args, &err_code))
goto out;
ha_warning("parsing [%s:%d]: the '%s' is deprecated and will be removed in a future version.\n",
file, linenum, args[0]);
}
else if (!strcmp(args[0], "dispatch")) { /* dispatch address */
struct sockaddr_storage *sk;