jordansissel / ruby-grok

Pure-ruby implementation of grok.
Apache License 2.0
54 stars 25 forks source link

How to get a match-list? #30

Closed lsyarn closed 7 years ago

lsyarn commented 7 years ago

I want to scan all the matches in port1:12.3-port3:11.5 with pattern -?port%{NUMBER:port}:%{NUMBER:data:float}?. But when I use grok.match(pattern), in the captures I only get port=1 and data=12.3 for the first match. How can I get a match-list for all the matches?