Logstash issue with json_formater [LogStash::Json::ParserError: Unexpected character ('-' (code 45)): was expecting comma to separate ARRAY entries]

Viewed 1439

I have an issue with converting value through logstash, I can't find solution for it. it seems to be linked to the date.

#Log line
[2017-08-15 12:30:17] api.INFO: {"sessionId":"a216925---ff5992be7520924ff25992be75209c7","action":"processed","time":1502789417,"type":"bookingProcess","page":"order"} [] []

Logstash configuration

filter {
        if [type] == "api-prod-log" {
                grok {
                        match => {"message" => "\[%{TIMESTAMP_ISO8601:timestamp}\] %{WORD:module}.%{WORD:level}: (?<log_message>.*) \[\] \[\]" }
                        add_field => [ "received_from", "%{host}" ]
                }
                json {
                    source => "log_message"
                    target => "flightSearchRequest"
                    remove_field=>["log_message"]
                }
                date {
                        match => [ "timestamp", "YYYY-MM-dd HH:mm:ss" ]
                        timezone => "Asia/Jerusalem"
                }
        }
}

Any idea ?

Thanks

1 Answers
Related