Skip to content

Commit aa70b3e

Browse files
committed
input_log: preserve non-conditional routes when conditional routing is used
Remove early return in input_log_append() that prevented non-conditional routes from receiving data when conditional routes existed. This ensures both conditional and non-conditional routes receive data in mixed configurations, preventing silent data loss from unconditional outputs. Signed-off-by: Eduardo Silva <[email protected]>
1 parent 9aa07ac commit aa70b3e

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

src/flb_input_log.c

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -756,13 +756,11 @@ static int input_log_append(struct flb_input_instance *ins,
756756
return -1;
757757
}
758758

759-
if (ret > 0) {
760-
if (processor_is_active && buf != out_buf) {
761-
flb_free(out_buf);
762-
}
763-
return 0;
764-
}
765-
759+
/*
760+
* Always call flb_input_chunk_append_raw to ensure non-conditional routes
761+
* receive data even when conditional routes exist. The conditional routing
762+
* should be additive, not exclusive.
763+
*/
766764
ret = flb_input_chunk_append_raw(ins, FLB_INPUT_LOGS, records,
767765
tag, tag_len, out_buf, out_size);
768766

0 commit comments

Comments
 (0)