DOC: configuration: clarify http-request wait-for-body
Make it more explicit what happens in the various scenarios that cause
HAProxy to stop waiting when "http-request wait-for-body" is used.
Also fix a couple of grammatical errors.
Fixes: #2410
Signed-Off-By: Thayne McCombs <astrothayne@gmail.com>
(cherry picked from commit 001bddf48c5e646466bd322817e8b4dc78c3760f)
Signed-off-by: Willy Tarreau <w@1wt.eu>
(cherry picked from commit 329935edf2c8d79ca81628510362fb12510e470b)
[wt: ctx adj]
Signed-off-by: Willy Tarreau <w@1wt.eu>
(cherry picked from commit 77f35914f6ced9f02aeacf2e3166a991ccde0ec4)
Signed-off-by: Christopher Faulet <cfaulet@haproxy.com>
(cherry picked from commit 1e66d9b421165455fc282e29add5545dc6364c14)
Signed-off-by: Christopher Faulet <cfaulet@haproxy.com>
(cherry picked from commit 259b377087f45e35400617c42937c23f5bf20ced)
Signed-off-by: Christopher Faulet <cfaulet@haproxy.com>
diff --git a/doc/configuration.txt b/doc/configuration.txt
index b4666f7..e733a2c 100644
--- a/doc/configuration.txt
+++ b/doc/configuration.txt
@@ -7024,13 +7024,21 @@
http-request wait-for-body time <time> [ at-least <bytes> ]
[ { if | unless } <condition> ]
- This will delay the processing of the request waiting for the payload for at
- most <time> milliseconds. if "at-least" argument is specified, HAProxy stops
- to wait the payload when the first <bytes> bytes are received. 0 means no
- limit, it is the default value. Regardless the "at-least" argument value,
- HAProxy stops to wait if the whole payload is received or if the request
- buffer is full. This action may be used as a replacement to "option
- http-buffer-request".
+ This will delay the processing of the request or response until one of the
+ following conditions occurs:
+ - The full request body is received, in which case processing proceeds
+ normally.
+ - <bytes> bytes have been received, when the "at-least" argument is given and
+ <bytes> is non-zero, in which case processing proceeds normally.
+ - The request buffer is full, in which case processing proceeds normally. The
+ size of this buffer is determined by the "tune.bufsize" option.
+ - The request has been waiting for more than <time> milliseconds. In this
+ case HAProxy will respond with a 408 "Request Timeout" error to the client
+ and stop processing the request. Note that if any of the other conditions
+ happens first, this timeout will not occur even if the full body has
+ not yet been recieved.
+
+ This action may be used as a replacement for "option http-buffer-request".
Arguments :
@@ -7039,7 +7047,7 @@
<bytes> is optional. It is the minimum payload size to receive to stop to
wait. It follows the HAProxy size format and is expressed in
- bytes.
+ bytes. A value of 0 (the default) means no limit.
Example:
http-request wait-for-body time 1s at-least 1k if METH_POST