fluent / fluent/fluent-bit

Parser: invalid time format error when comma appears in format string

Open
#524 4 comments 5 reactions 1 assignee Claimed by @edsiper View on GitHub
enhancement
Dominant language
C
Stars
8.1k
Forks
2k
Avg merge
4d 20h
Merged PRs (30d)
71

Description

fluent-bit version: 0.12.14

We are trying to parse timestamps with the following format in a tail input:

2018-03-01 17:46:03,781

We are using a parser time format defined as follows:

Time_Format %Y-%m-%d %H:%M:%S,%L

This results in the following error on startup:

[error] [parser:foo] Invalid time format %Y-%m-%d %H:%M:%S,%L.

And of course we do not get the timestamp in the output record. If I remove the ",%L" from the format string the error disappears, but obviously the format no longer matches.

I have tried quoting the format string, but that did not resolve the issue. Also note that we successfully used this same format string in custom confs for google-fluentd to log to stackdriver.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.