Open pmeier opened 4 months ago
I'm certainly no expert on the code base, but IMO the reset needs to happen in
and according to this comment
probably has to be guarded with if (forced_flush) {...}
.
This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 5 days. Maintainers can add the exempt-stale
label.
Still relevant.
Bug Report
To Reproduce
We are running a configuration where we are looking for a trigger (
bar
) in the log message and keep appending messages until we see the trigger again.fluent-bit.conf
parsers.conf
test.log
Run
Grouping
foo 2
andfoo 3
withbar 1
is correct. But after the flush timeout triggered we are still stuck in the state machine. So when we appendfoo 4
andfoo 5
to the file, they are merged together although parser never saw thebar
trigger again.foo 6
is the correctly put as single record, because afterwards we have thebar 7
trigger. But afterwardsfoo 8
andfoo 9
are again erroneously merged together.Expected behavior
foo 4
andfoo 5
as well asfoo 8
andfoo 9
should be single lines and not be merged.Your Environment
Additional context
As the whole point of the multiline parser is to merge multiple records, I don't think it makes any sense to not reset the state machine as soon as something is emitted by the
flush_timeout
.