Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions docs/changelog/113975.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
pr: 113975
summary: JDK locale database change
area: Mapping
type: breaking
issues: []
breaking:
title: JDK locale database change
area: Mapping
details: |
{es} 8.16 changes the version of the JDK that is included from version 22 to version 23. This changes the locale database that is used by Elasticsearch from the COMPAT database to the CLDR database. This change can cause significant differences to the textual date formats accepted by Elasticsearch, and to calculated week-dates.

If you run {es} 8.16 on JDK version 22 or below, it will use the COMPAT locale database to match the behavior of 8.15. However, starting with {es} 9.0, {es} will use the CLDR database regardless of JDK version it is run on.
impact: |
This affects you if you use custom date formats using textual or week-date field specifiers. If you use date fields or calculated week-dates that change between the COMPAT and CLDR databases, then this change will cause Elasticsearch to reject previously valid date fields as invalid data. You might need to modify your ingest or output integration code to account for the differences between these two JDK versions.

Starting in version 8.15.2, Elasticsearch will log deprecation warnings if you are using date format specifiers that might change on upgrading to JDK 23. These warnings are visible in Kibana.

For detailed guidance, refer to <<custom-date-format-locales,Differences in locale information between JDK versions>> and the https://ela.st/jdk-23-locales[Elastic blog].
notable: true
4 changes: 2 additions & 2 deletions docs/reference/mapping/params/format.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -34,13 +34,13 @@ down to the nearest day.
Completely customizable date formats are supported. The syntax for these is explained in
https://docs.oracle.com/en/java/javase/21/docs/api/java.base/java/time/format/DateTimeFormatter.html[DateTimeFormatter docs].

Note that whilst the built-in formats for week dates use the ISO definition of weekyears,
Note that while the built-in formats for week dates use the ISO definition of weekyears,
custom formatters using the `Y`, `W`, or `w` field specifiers use the JDK locale definition
of weekyears. This can result in different values between the built-in formats and custom formats
for week dates.

[[built-in-date-formats]]
==== Built In Formats
==== Built-in formats

Most of the below formats have a `strict` companion format, which means that
year, month and day parts of the month must use respectively 4, 2 and 2 digits
Expand Down