-
Notifications
You must be signed in to change notification settings - Fork 32
Open
Description
Hello,
I'm trying to use the grok-js module with the following pattern :
%{TIMESTAMP_ISO8601:date} \| %{IP:client} \| %{WORD:method} \| %{URIPATHPARAM:request} \| %{NUMBER:bytes:int} \| %{NUMBER:duration:int}
and the following line :
2018-04-11 15:26:04.756 | 192.168.0.19 | GET | /uri | 18 | 2
Unfortunately, the module doesn't work with types. If I change the pattern like this
%{TIMESTAMP_ISO8601:date} \| %{IP:client} \| %{WORD:method} \| %{URIPATHPARAM:request} \| %{NUMBER:bytes} \| %{NUMBER:duration}
Everything works.
So to fix this issue, I had to change the subPatternsRegex
From
const subPatternsRegex = /%\{[A-Z0-9_]+(?::[A-Za-z0-9_]+)?\}/g;To
const subPatternsRegex = /%\{[A-Z0-9_]+(?::[A-Za-z0-9_]+)?(?::[a-z]+)?\}/g;Metadata
Metadata
Assignees
Labels
No labels