Without check-reuse-pool, it is impossible to perform check on server
using @rhttp protocol. This is due to the inherent nature of the
protocol which does not implement an active connect method.
Thus, ensure that check-reuse-pool is always set when a reverse HTTP
server is declared. This reduces server configuration and should prevent
any omission. Note that it is still require to add "check" server
keyword so activate server checks.
any specific check connect option is defined, either on the server line or
via a custom tcp-check connect rule.
- If checks are activated for a reverse HTTP server, this option is mandatory
- for checks to succeed, as by definition these servers do not have the ability
- to initiate connection.
+ This option is automatically enabled for servers acting as passive reverse
+ HTTP gateway, as for those servers connect is only supported through reuse.
check-send-proxy
May be used in the following contexts: tcp, http
srv->check.sni = src->check.sni;
srv->check.alpn_str = src->check.alpn_str;
srv->check.alpn_len = src->check.alpn_len;
- srv->check.reuse_pool = src->check.reuse_pool;
+ if (!(srv->flags & SRV_F_RHTTP))
+ srv->check.reuse_pool = src->check.reuse_pool;
/* Note: 'flags' field has potentially been already initialized. */
srv->flags |= src->flags;
srv->do_check = src->do_check;
}
else {
newsrv->flags |= SRV_F_RHTTP;
+ /* Automatically activate check-reuse-pool for rhttp@ servers. */
+ newsrv->check.reuse_pool = 1;
}
}