logstash-filter-json icon indicating copy to clipboard operation
logstash-filter-json copied to clipboard

problem parsing json arrays

Open necroscope opened this issue 10 years ago • 3 comments

Hi, Please help. The array values are not appearing as name value pairs in kibana as the json filter does not parse nested arrays.

Here is my json: {"metric_data":{"from":"2015-06-23T06:11:52+00:00","to":"2015-06-23T06:12:52+00:00","metrics":[{"name":"HttpDispatcher","timeslices":[{"from":"2015-06-23T06:10:00+00:00","to":"2015-06-23T06:11:00+00:00","values":{"average_call_time":486,"call_count":1849}}]}]}}

I want to be able to search in kibana or create dashboard on average call time but logstash puts the whole json string under metric_data.metrics and _source in kibana/ES. Is does not parse out the name value pairs such as average_call_time: 486

Please assist thanks!

necroscope avatar Jun 23 '15 20:06 necroscope

I have the exact same issue. If a field or subfield within a JSON blob is an array, the JSON filter fails to parse the array, and just returns it as string.

FlorinAndrei avatar Feb 01 '16 23:02 FlorinAndrei

You can find an example here

catalinvr avatar Apr 26 '16 15:04 catalinvr

👍

jonathanpmartins avatar Jun 01 '16 11:06 jonathanpmartins