mirror of
http://git.haproxy.org/git/haproxy.git
synced 2026-02-17 21:06:52 +02:00
MINOR: log: custom name for logformat node
Add the ability to specify custom name (will be used for representation in verbose output types such as json) to logformat nodes. For now, a custom name should be composed by characters [a-zA-Z0-9-_]*
This commit is contained in:
@@ -200,6 +200,8 @@ enum {
|
||||
LF_SEPARATOR, // a single separator
|
||||
LF_VAR, // variable name, after '%' or '%{..}'
|
||||
LF_STARTVAR, // % in text
|
||||
LF_STONAME, // after '%(' and before ')'
|
||||
LF_EDONAME, // ')' after '%('
|
||||
LF_STARG, // after '%{' and berore '}'
|
||||
LF_EDARG, // '}' after '%{'
|
||||
LF_STEXPR, // after '%[' or '%{..}[' and berore ']'
|
||||
@@ -212,6 +214,7 @@ struct logformat_node {
|
||||
struct list list;
|
||||
int type; // LOG_FMT_*
|
||||
int options; // LOG_OPT_*
|
||||
char *name; // printable name for output types that require named fields (ie: json)
|
||||
char *arg; // text for LOG_FMT_TEXT, arg for others
|
||||
void *expr; // for use with LOG_FMT_EXPR
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user