diff --git a/doc/configuration.txt b/doc/configuration.txt index 2d169fd27..c06458484 100644 --- a/doc/configuration.txt +++ b/doc/configuration.txt @@ -2464,7 +2464,10 @@ expose-experimental-directives breaking them but with no guarantee. For these reasons, these features are not expected to be supported beyond the release of the next LTS release. Users who want to try experimental features are expected to upgrade quickly - to benefit from the improvements made to that feature. + to benefit from the improvements made to that feature. In order to know if + this directive is still needed, it's easy: if it is enabled without being + used by any such feature, a warning will be emitted suggesting to turn it + off. So without any warning, it means it's still needed. external-check [preserve-env] Allows the use of an external agent to perform health checks. This is diff --git a/src/cfgparse.c b/src/cfgparse.c index 288502b61..a36e88983 100644 --- a/src/cfgparse.c +++ b/src/cfgparse.c @@ -4609,6 +4609,14 @@ init_proxies_list_stage2: cfgerr += postparser->func(); } + if (experimental_directives_allowed && + !(get_tainted() & TAINTED_CONFIG_EXP_KW_DECLARED)) { + ha_warning("Option 'expose-experimental-directives' is set in the global section but is " + "no longer used. It is strongly recommended to remove it in order to avoid " + "using an experimental directive by accident in the future.\n"); + err_code |= ERR_WARN; + } + if (cfgerr > 0) err_code |= ERR_ALERT | ERR_FATAL; out: