Here is my configuration:
"[log][timestamp]" => "%{[yearinlog]}-%{[monthinlog]}-%{[dateinlog]} %{[hourinlog]}:%{[minuteinlog]}:%{[secondinlog]}"
}
}
date {
match => [
"[log][timestamp]",
"yyyy-MM-dd HH:mm:ss.SSS000"
]
timezone => "Asia/Singapore"
target => "@timestamp"
}
I am trying to parse into elastic search but i am getting these as shown below. Any ideas how I can fix this?
Could not index event to Elasticsearch. {:status=>400, :action=>["index", {:_id=>nil, :_index=>"filebeat-mneta-app-2021.01.14", :_type=>"_doc", :routing=>nil}, #LogStash::Event:0x3091220c], :response=>{"index"=>{"_index"=>"filebeat-mneta-app-2021.01.14", "_type"=>"_doc", "_id"=>"dEfHGHcBobdQVkyHZgd2", "status"=>400, "error"=>{"type"=>"mapper_parsing_exception", "reason"=>"failed to parse field [log.timestamp] of type [date] in document with id 'dEfHGHcBobdQVkyHZgd2'. Preview of field's value: '2021-01-15 03:32:11.874'", "caused_by"=>{"type"=>"illegal_argument_exception", "reason"=>"failed to parse date field [2021-01-15 03:32:11.874] with format [strict_date_optional_time||epoch_millis]", "caused_by"=>{"type"=>"date_time_parse_exception", "reason"=>"Failed to parse with all enclosed parsers"}}}}}}