BUG/MEDIUM: http-ana: Preserve response's FLT_END analyser on L7 retry
authorChristopher Faulet <cfaulet@haproxy.com>
Tue, 4 Jan 2022 09:56:03 +0000 (10:56 +0100)
committerWilly Tarreau <w@1wt.eu>
Mon, 10 Jan 2022 07:53:15 +0000 (08:53 +0100)
commitfc8ff21d0cca5b316f3821a7f8588db28896e04b
tree8f32a721645f7c22b4c2d9d2acf31f3f2c071a0e
parent5ca0d91e56de1511680d31c6cd65761db56f4a7d
BUG/MEDIUM: http-ana: Preserve response's FLT_END analyser on L7 retry

When a filter is attached on a stream, the FLT_END analyser must not be
removed from the response channel on L7 retry. It is especially important
because CF_FLT_ANALYZE flag is still set. This means the synchronization
between the two sides when the filter ends can be blocked. Depending on the
timing, this can freeze the stream infinitely or lead to a spinning loop.

Note that the synchronization between the two sides at the end of the
analysis was introduced because the stream was reused in HTTP between two
transactions. But, since the HTX was introduced, a new stream is created for
each transaction. So it is probably possible to remove this step for 2.2 and
higher.

This patch must be backported as far as 2.0.

(cherry picked from commit 7bf46bb9a972c1e9de50b31ce20811f2f59a6849)
Signed-off-by: Willy Tarreau <w@1wt.eu>
(cherry picked from commit 5ece3ae8cca1267f83b2cd82cca67e8ceb42610f)
Signed-off-by: Willy Tarreau <w@1wt.eu>
(cherry picked from commit 42d4ee13a00e43311abfbc953640f52e719fe0a7)
Signed-off-by: Willy Tarreau <w@1wt.eu>
src/http_ana.c