-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
enhancement(docker source): Multiline support (#3607)
* enhancement(docker source): Multiline support Signed-off-by: MOZGIII <mike-n@narod.ru> * Share the multiline docs among the file and docker source Signed-off-by: MOZGIII <mike-n@narod.ru> * Add test Signed-off-by: MOZGIII <mike-n@narod.ru>
- Loading branch information
Showing
4 changed files
with
194 additions
and
83 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
[<%= namespace %>.options.multiline] | ||
type = "table" | ||
category = "Multiline" | ||
description = """\ | ||
Multiline parsing configuration. | ||
If not speicified, multiline parsing is disabled.\ | ||
""" | ||
|
||
[<%= namespace %>.options.multiline.children.start_pattern] | ||
type = "string" | ||
category = "Multiline" | ||
examples = ["^[^\\s]", "\\\\$", "^(INFO|ERROR) ", "[^;]$"] | ||
required = true | ||
sort = 1 | ||
description = """\ | ||
Start regex pattern to look for as a beginning of the message.\ | ||
""" | ||
|
||
[<%= namespace %>.options.multiline.children.condition_pattern] | ||
type = "string" | ||
category = "Multiline" | ||
examples = ["^[\\s]+", "\\\\$", "^(INFO|ERROR) ", ";$"] | ||
required = true | ||
sort = 3 | ||
description = """\ | ||
Condition regex pattern to look for. Exact behavior is configured via `mode`.\ | ||
""" | ||
|
||
[<%= namespace %>.options.multiline.children.mode] | ||
type = "string" | ||
category = "Multiline" | ||
required = true | ||
sort = 2 | ||
description = """\ | ||
Mode of operation, specifies how the `condition_pattern` is interpreted.\ | ||
""" | ||
|
||
[<%= namespace %>.options.multiline.children.mode.enum] | ||
continue_through = """\ | ||
All consecutive lines matching this pattern are included in the group. \ | ||
The first line (the line that matched the start pattern) does not need \ | ||
to match the `ContinueThrough` pattern. \ | ||
This is useful in cases such as a Java stack trace, where some indicator \ | ||
in the line (such as leading whitespace) indicates that it is an \ | ||
extension of the preceeding line.\ | ||
""" | ||
continue_past = """\ | ||
All consecutive lines matching this pattern, plus one additional line, \ | ||
are included in the group. \ | ||
This is useful in cases where a log message ends with a continuation \ | ||
marker, such as a backslash, indicating that the following line is part \ | ||
of the same message.\ | ||
""" | ||
halt_before = """\ | ||
All consecutive lines not matching this pattern are included in the \ | ||
group. \ | ||
This is useful where a log line contains a marker indicating that it \ | ||
begins a new message.\ | ||
""" | ||
halt_with = """\ | ||
All consecutive lines, up to and including the first line matching this \ | ||
pattern, are included in the group. \ | ||
This is useful where a log line ends with a termination marker, such as \ | ||
a semicolon.\ | ||
""" | ||
|
||
[<%= namespace %>.options.multiline.children.timeout_ms] | ||
type = "uint" | ||
category = "Multiline" | ||
examples = [1000, 600000] | ||
unit = "milliseconds" | ||
common = true | ||
required = true | ||
sort = 4 | ||
description = """\ | ||
The maximum time to wait for the continuation. Once this timeout is \ | ||
reached, the buffered message is guaraneed to be flushed, even if \ | ||
incomplete.\ | ||
""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters