Skip to content

LTSV decoder doesn't respect output.ltsv_extra add or replace fields #39

@kurojishi

Description

@kurojishi

Found this while writing tests

As for https://github.com/jedisct1/flowgger/wiki/LTSV-Encoder the encoders should support the ability to add or replace, without duplicating tags and fields.

LTSV is not only not overriding it, but get duplicated as the encoding is done by appending data to a String:

https://github.com/awslabs/flowgger/blob/master/src/flowgger/encoder/ltsv_encoder.rs#L41

left: "some_info:foo\tsome_info:bar\thost:example.org\ttime:1385053862.3072\tmessage:A short message\tfull_message:Backtrace here with more\tlevel:1\tappname:appname\tprocid:44\tmsgid:msg_id",
right: "some_info:bar\thost:example.org\ttime:1385053862.3072\tmessage:A short message\tfull_message:Backtrace here with more\tlevel:1\tappname:appname\tprocid:44\tmsgid:msg_id"', src/flowgger/encoder/ltsv_encoder.rs:175:9

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions