Hi,
I am trying to convert data type of timestamp extracted with grok pattern, as described in documentation:
%{DATA:timestamp;date;dd/MMM/yyyy:HH:mm:ss Z}
Formatted time looks like this: 2018-04-19 13:01:24,450
I am using TIMESTAMP_ISO8601
to extract this data, and if i do this, it does work:
%{TIMESTAMP_ISO8601:timestamp;date;yyyy-MM-dd HH:mm:ss}
But i’m losing miliseconds. If i add miliseconds, like so:
%{TIMESTAMP_ISO8601:timestamp;date;yyyy-MM-dd HH:mm:ss,SSS}
…i get this error:
We were not able to run the grok extraction. Please check your parameters.
Details: Error: cannot POST http://hostname:9000/api/tools/grok_tester (500)
Error response looks like this:
{"type":"ApiError","message":"Illegal repetition near index ...
It seems ,
character inside SimpleDateFormat expression yyyy-MM-dd HH:mm:ss,SSS
is the issue. Are there any workarounds? I tried escaping it with \
but it didn’t help.