Logstash does not parse json

后端 未结 3 1424
滥情空心
滥情空心 2020-12-09 12:37

When i see results in Kibana, i see that there are no fields from JSON, more over, message field contains only \"status\" : \"FAILED\".

Is

3条回答
  •  谎友^
    谎友^ (楼主)
    2020-12-09 13:22

    Try the json_lines codec instead of json. This must have been added recently. In your particular case, you'd first want to change your output from a list of json to newline-delimited json.

    http://logstash.net/docs/1.4.0/codecs/json_lines

    This codec will decode streamed JSON that is newline delimited. For decoding JSON payload in the redis input for example, use the json codec instead. Encoding will emit a single JSON string ending in a '\n'

提交回复
热议问题