mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2025-09-21 13:51:26 +02:00
DOC: config: document proxy "log-steps" keyword
Now that "log-steps" proxy keyword is functional, let's add some documentation and usage examples for it.
This commit is contained in:
parent
e3eb6a9035
commit
7ad4e00c1f
@ -5422,6 +5422,7 @@ log (*) X X X X
|
||||
log-format X X X -
|
||||
log-format-sd X X X -
|
||||
log-tag X X X X
|
||||
log-steps X X X -
|
||||
max-keep-alive-queue X - X X
|
||||
max-session-srv-conns X X X -
|
||||
maxconn X X X -
|
||||
@ -8574,6 +8575,44 @@ log-format-sd <fmt>
|
||||
Example :
|
||||
log-format-sd [exampleSDID@1234\ bytes=\"%B\"\ status=\"%ST\"]
|
||||
|
||||
log-steps <steps>
|
||||
Specifies at which steps during transaction processing logs should be
|
||||
generated.
|
||||
|
||||
May be used in the following contexts: tcp, http
|
||||
|
||||
May be used in sections: defaults | frontend | listen | backend
|
||||
yes | yes | yes | no
|
||||
|
||||
During tcp/http transaction processing, haproxy may produce logs at different
|
||||
steps during the processing (ie: accept, connect, request, response, close).
|
||||
|
||||
By default, HAProxy emits a single log per transaction, once all of the
|
||||
items used in the logformat expression could be satisfied, which means
|
||||
that in practice the log is usually emitted at the end of the transaction
|
||||
(after the end of the response for HTTP or end of connection for TCP),
|
||||
unless "option logasap" is used.
|
||||
|
||||
The "log-steps" directive allows to refine the precise instants where
|
||||
logs will be emitted, and even permits to emit multiple logs for a
|
||||
same transaction. Special value 'all' may be used to enable all available
|
||||
log origins, making it possible to track a transaction from accept to close.
|
||||
Indidivual log origins may also be specified using their names separated by
|
||||
spaces to selectively enable when logs should be produced.
|
||||
|
||||
Common log origins are: accept, connect, request, response, close.
|
||||
|
||||
Example:
|
||||
frontend myfront
|
||||
option httplog
|
||||
log-steps accept,close #only log accept and close for the txn
|
||||
|
||||
Log origins specified as "logging steps" (such as accept, close) can be
|
||||
used as-is in log-profiles (after 'on' directive). Combining "log-steps"
|
||||
with log-profiles is really interesting to have fine-grained control over
|
||||
logs automatically generated by haproxy during transaction processing.
|
||||
|
||||
See also : "log-profile"
|
||||
|
||||
log-tag <string>
|
||||
Specifies the log tag to use for all outgoing logs
|
||||
|
Loading…
x
Reference in New Issue
Block a user