Skip to content
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

Core: Backport java time date formatters #31997

Merged
merged 4 commits into from
Jul 16, 2018

Conversation

spinscale
Copy link
Contributor

This backports 1c32497, 1c32497 and #31995 to provide those dateformatters for the planned java time/joda time BWC layer

@spinscale spinscale added review :Core/Infra/Core Core issues without another label v6.4.0 labels Jul 12, 2018
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-core-infra

A newly added class called DateFormatters now contains java.time based
builders for dates, which also intends to be fully backwards compatible,
when the name based date formatters are picked. Also a new class named
CompoundDateTimeFormatter for being able to parse multiple different
formats has been added.

A duelling test class has been added that ensures the same dates when
parsing java or joda time formatted dates for the name based dates.

Note, that java.time and joda time are not fully backwards compatible,
which also means that old formats will currently not work with this
setup.
This also extends the dateformatters test to ensure that the printers
are acting the same in java time and joda time.
This test produced different implementations of joda time classes,
depending on if the data was serialized or not (DateTime vs
MutableDateTime). This now uses a common base class to extract the
milliseconds from the data.

Closes elastic#31992
@spinscale spinscale force-pushed the 1807-backport-datetimeformatters branch from 2a0be65 to 2c3040f Compare July 16, 2018 12:19
@rjernst rjernst merged commit a87ae91 into elastic:6.x Jul 16, 2018
@rjernst
Copy link
Member

rjernst commented Jul 16, 2018

Thanks @spinscale

martijnvg added a commit that referenced this pull request Jul 17, 2018
* es/6.x:
  Scripting: Remove dead code from painless module (#32064) (#32104)
  Painless: Move and Rename Several Methods in the lookup package (#32105)
  Bypass highlight query terms extraction on empty fields (#32090)
  Core: Backport java time date formatters (#31997)
  Switch non-x-pack to new style requests (#32106)
  SQL: allow LEFT and RIGHT as function names (#32066)
  Painless: Separate PainlessLookup into PainlessLookup and PainlessLookupBuilder (#32054)
  [test] turn on host io cache for opensuse (#32053)
  DOCS: put LIMIT 10 to the SQL query (#32065)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Core/Infra/Core Core issues without another label >non-issue v6.4.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants