Use a low-fat quantifier:
test:(.*?),
Or character class:
test:([^,]*),
Ignore comma:
test:([^,]*)
If you want to omit test:, you can also use the look:
(?<=test:\s)[^,]*
Since you are using this grok debugger , I managed to get this to work using the named capture group:
(?<test>(?<=test:\s)[^,]*)
source
share