MINOR: http-fetch: Add a sample to retrieve the server status code
authorChristopher Faulet <cfaulet@haproxy.com>
Mon, 27 Nov 2023 17:12:13 +0000 (18:12 +0100)
committerChristopher Faulet <cfaulet@haproxy.com>
Wed, 29 Nov 2023 10:11:12 +0000 (11:11 +0100)
commitb2f82b2b51ffa90ae0463f5fb2fe60b24d856bb3
tree4b7c14bc6b1c4683479f9549cec34566fa7a830e
parent263f4e3d9cffbe22716db817a09c416d5c82f6fa
MINOR: http-fetch: Add a sample to retrieve the server status code

The code returned by the "status" sample fetch is the one in the HTTP
response at the moment the sample is evaluated. It may be the status code in
the server response or the one of the HAProxy reply in case of error, deny,
redirect...

However, it could be handy to retrieve the status code returned by the
server, when a HTTP response was really received from it. It is the purpose
of the "server_status" sample fetch. The server status code itself is stored
in the HTTP txn.
doc/configuration.txt
include/haproxy/http_ana-t.h
src/http_ana.c
src/http_fetch.c