Date parsing issue - ElasticSearch 7.6

Hi everyone,

I recently migrated from ElasticSearch 6.8 to 7.6 and i have an issue with the date format

I'm pushing documents to ElasticSearch with the following format :

yyyy-MM-dd'T'HH:mm:ssZ

I red the following links (an others) on the best practise and issues :
https://www.elastic.co/guide/en/elasticsearch/reference/current/date.html
https://www.elastic.co/guide/en/elasticsearch/reference/7.x/breaking-changes-7.0.html

When i try to put new documents to ES, i get the following error :

Elasticsearch exception [type=illegal_argument_exception, reason=unable to parse date [2020-04-27T15:14:11Z]]]; nested: ElasticsearchException[Elasticsearch exception [type=illegal_argument_exception, reason=failed to parse date field [2020-04-27T15:14:11Z] with format [8yyyy-MM-dd'T'HH:mm:ssZ]]]; nested: ElasticsearchException[Elasticsearch exception [type=date_time_parse_exception, reason=Text '2020-04-27T15:14:11Z' could not be parsed at index 19

My current pipeline has the following date format :

"formats" : [ "yyyy-MM-dd'T'HH:mm:ssX", "yyyy-MM-dd'T'HH:mm:ss.SSSX" ],

I don't specify any date format in the mapping as it didn't work when i tried, but maybe i did it wrong.

What would work with my current configuration ? Any help would be much appreciated,

Thanks in advance !

Fixed !

The pipeline was the solution, it didn't match the format used in the files. Now it does.
Closing the issue

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