awslabs / flowgger

A fast data collector in Rust
BSD 2-Clause "Simplified" License
834 stars 55 forks source link

Add timestamps #77

Closed peterwa88 closed 1 year ago

peterwa88 commented 1 year ago

How can I add timestamp into each forwarded message in flowgger?

peterwa88 commented 1 year ago

The following configuration does not work.

[input] type = "tcp" ----->input message can be any type, I just want to add timestamp to each receive data package. listen = "127.0.0.1:22" framing = "line"

[output] type = "stdout" match = "*" format = "json" add_timestamp = true

vche commented 1 year ago

Hi ! Yes, yes, please check the documentation, and use the syslog_prepend_timestamp option.