rewrite_tag
filter, allows to re-emit a record under a new Tag. Once a record has been re-emitted, the original record can be preserved or discarded.rewrite_tag
filter supports the following configuration parameters:KEY REGEX NEW_TAG KEEP
. For more specific details of the Rule format and it composition read the next section.memory
(default) or filesystem
. If the destination for the new records generated might face backpressure due to latency or slow network, we strongly recommend enabling the filesystem
mode.10M
. The pipeline will pause once the buffer exceeds the value of this setting. For example, if the value is set to 10M
then the pipeline will pause if the buffer exceeds 10M
. The pipeline will remain paused until the output drains the buffer below the 10M
limit.$
. Consider the following structured record (formatted for readability):name
we must use $name
. The key selector is flexible enough to allow to match nested levels of sub-maps from the structure. If we wanted to check the value of the nested key s2
we can do it specifying $ss['s1']['s2']
, for short:$name
= "abc-123"$ss['s1']['s2']
= "flb"$name
contains a value of the format string-number
like the example provided above, we might use:$name
equals abc-123
, then the following placeholders will be created:$0
= "abc-123"$1
= "abc"$2
= "123"a-z
,A-Z
, 0-9
and .-,
.{"name": "abc-123", "ss": {"s1": {"s2": "flb"}}}
true
or false
to decide the expected behavior. There is no default value and this is a mandatory field in the rule.test_tag
will be rewritten as from.test_tag.new.fluent.bit.out
:drop_records
and add_records
, they summarize the total of dropped records from the incoming data chunk or the new records added.rewrite_tag
emit new records that goes through the beginning of the pipeline, it exposes an additional metric called emit_records
that summarize the total number of emitted records.emitter_for_rewrite_tag.0
.rewrite_tag
creates an Emitter instance to use it exclusively to emit records, on that way we can have a granular control of who is emitting what.Emitter_Name
configuration property described above.