1
1
mirror of https://github.com/tstack/lnav.git synced 2024-09-11 13:05:51 +03:00

[piper] add some demux debug log

This commit is contained in:
Tim Stack 2024-05-27 07:23:07 -07:00
parent f4f207f641
commit a28ddb7196
2 changed files with 9 additions and 1 deletions

View File

@ -118,6 +118,14 @@ multiplex_matcher::match(const string_fragment& line)
log_info(" and required captures were found, using demuxer");
return found{demux_pair.first};
}
auto partial_size = df.dd_pattern.pp_value->match_partial(line);
if (partial_size > 0) {
log_info(" only partial match by pattern: %s",
df.dd_pattern.pp_value->get_pattern().c_str());
log_info(" %s",
line.sub_range(0, partial_size).to_string().c_str());
}
}
if (df.dd_control_pattern.pp_value) {
md = df.dd_control_pattern.pp_value->create_match_data();

View File

@ -26,7 +26,7 @@
},
"demux": {
"container": {
"pattern": "^(?:\\x1b\\[\\d*K)?(?<mux_id>[a-zA-Z0-9][a-zA-Z0-9_\\.\\-]*)\\s+\\| (?<timestamp>\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}.\\d{9}Z )?(?<body>.*)"
"pattern": "^(?:\\x1b\\[\\d*K)?(?<mux_id>[a-zA-Z0-9][\\@a-zA-Z0-9_\\.\\-]*)\\s+\\| (?<timestamp>\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}.\\d{9}Z )?(?<body>.*)"
},
"recv-with-pod": {
"control-pattern": "^===== (?:START|END) =====$",