Logstash error: cannot parse empty date

Hi all,

i want to load data from an api to elasticserach via logstash.
i have a field "depDate" with date type ....in some documents, this field can be empty .
what can i do to load this documents in my index ?
[2020-09-09T09:49:57,579][WARN ][logstash.outputs.elasticsearch][main][fed23d7d9bfa7507f60b2d65f38c4267d771d4cffdd05c45a32b8c5349f75058
] Could not index event to Elasticsearch.
{:status=>400, :action=>["update", {:_id=>"553512", :_index=>"book_v1", :routing=>nil, :_type=>"_doc", :retry_on_conflict=>1}, #LogStash::Event:0x64601638],
:response=>{"update"=>{"_index"=>"book_v1", "_type"=>"_doc", "_id"=>"553512", "status"=>400, "error"=>{"type"=>"mapper_parsing_exception",
"reason"=>"failed to parse field [depDate] of type [date] in document with id '553512'. Preview of field's value: ''",
"caused_by"=>{"type"=>"illegal_argument_exception", "reason"=>"cannot parse empty date"}}}}}

any help please!

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.