-
Notifications
You must be signed in to change notification settings - Fork 25.2k
ES 7 changes which dates date_optional_time
can successfully parse
#72191
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
date_optional_time
can successfully parsedate_optional_time
can successfully parse
Pinging @elastic/es-search (Team:Search) |
@pgomulka do you have an opinion on this? I see we accepted up to 9 digits in 6.8 (I see from an error message in 6.8 that "year must be in the range [-292275055,292278994]") but maybe the restriction to 5 digits was introduced in 7x on purpose and this should be a documentation issue? I don't know all the background around these decisions I'm afraid. |
this might be a bug. As stated in joda 'non strict' |
…l_time (elastic#73034) We changed the default joda behaviour in strict_date_optional_time to max 4 digits in a year. Java.time implementation should behave the same way. At the same time date_optional_time should have 9digits for year part. closes elastic#52396 closes elastic#72191
Uh oh!
There was an error while loading. Please reload this page.
Elasticsearch version (
bin/elasticsearch --version
):Plugins installed: []
JVM version (
java -version
):OS version (
uname -a
if on a Unix-like system):Description of the problem including expected versus actual behavior:
The values that the
date_optional_time
format can successfully parse have changed in ElasticSearch 7.It seems to be related to dates where the year includes more than 5 digits.
I understand that ES7 includes a migration from Joda time formatters to Java time formatters and there are some expected breaking changes - as documented in the Java time migration guide.
This change in behaviour could be deliberate, but it's not clear from the documentation that this migration affects the
date_optional_time
built-in format. From the docs:Steps to reproduce:
date
field using thedate_optional_time
format:Error response:
Example of this working successfully in ES6.8:
Response:
The text was updated successfully, but these errors were encountered: