Skip to content

How to properly handle timestamps in a rsyslog -> telegraf syslog input -> telegraf loki output -> greptime loki input workflow? #6269

Answered by shuiyisong
jerrac asked this question in Q&A
Discussion options

You must be logged in to vote

Hi,
Thanks for trying out GreptimeDB :)

First of all, the values you extracted from the regex are all strings (I'm sure you've figured it out!).

In the transform section, the type field is set to specify the datatype in the database tables. The pipeline engine will try to 'convert' the type from the context to the desired one. In this case, line_timestamp is a string, and the target type is a timestamp in the database (nanosecond timestamp, to be specific. The type description here only states information about the target type, doesn't carry any information about the input type). The pipeline engine will have no idea what the string looks like (is it a date string, or epoch digits?), so i…

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@jerrac
Comment options

@shuiyisong
Comment options

Answer selected by jerrac
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants