Skip to content

Commit b7355a6

Browse files
bazsiHofiOne
authored andcommitted
cfg-grammar: make idle-timeout configurable for LogReader based sources
Signed-off-by: Balazs Scheidler <[email protected]> Signed-off-by: Hofi <[email protected]>
1 parent 3daa97b commit b7355a6

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

lib/cfg-grammar.y

+3
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,7 @@
213213
%token KW_BATCH_LINES 10087
214214
%token KW_BATCH_TIMEOUT 10088
215215
%token KW_TRIM_LARGE_MESSAGES 10089
216+
216217
%token KW_STATS 10400
217218
%token KW_FREQ 10401
218219
%token KW_LEVEL 10402
@@ -228,6 +229,7 @@
228229
%token KW_CHECK_HOSTNAME 10093
229230
%token KW_BAD_HOSTNAME 10094
230231
%token KW_LOG_LEVEL 10095
232+
%token KW_IDLE_TIMEOUT 10096
231233
%token KW_CHECK_PROGRAM 10097
232234

233235
%token KW_KEEP_TIMESTAMP 10100
@@ -1464,6 +1466,7 @@ source_proto_option
14641466
free($3);
14651467
}
14661468
| KW_LOG_MSG_SIZE '(' positive_integer ')' { last_proto_server_options->max_msg_size = $3; }
1469+
| KW_IDLE_TIMEOUT '(' positive_integer ')' { last_proto_server_options->idle_timeout = $3; }
14671470
| KW_TRIM_LARGE_MESSAGES '(' yesno ')' { last_proto_server_options->trim_large_messages = $3; }
14681471
;
14691472

lib/cfg-parser.c

+1
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,7 @@ static CfgLexerKeyword main_keywords[] =
151151
{ "log_iw_size", KW_LOG_IW_SIZE },
152152
{ "log_msg_size", KW_LOG_MSG_SIZE },
153153
{ "trim_large_messages", KW_TRIM_LARGE_MESSAGES },
154+
{ "idle_timeout", KW_IDLE_TIMEOUT },
154155
{ "log_prefix", KW_LOG_PREFIX, KWS_OBSOLETE, "program_override" },
155156
{ "program_override", KW_PROGRAM_OVERRIDE },
156157
{ "host_override", KW_HOST_OVERRIDE },

0 commit comments

Comments
 (0)