GitHub user ardlema opened a pull request:
https://github.com/apache/metamodel/pull/43
METAMODEL-172: Adding Date parsing to ES module
When working with ElasticSearch indexes that contains Date types the API is
returning Strings instead of proper Date objects. We found out this problem
querying an index with a time-zone format field.
Changes made in this PR:
- Added time-zone format dates support in the TimeComparator class
- Added a string to date direct conversion through the TimeComparator
class in the ElasticSearchUtils class that will convert the string from ES into
a proper Date (when the format will be supported by Metamodel)
- Added a new unit test for the ElasticSearchUtils class
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/ardlema/metamodel METAMODEL-172
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/metamodel/pull/43.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #43
----
commit 8ab1394b1fbb0bd144ccd9a2b8df959b7c82f729
Author: Alberto Rodriguez <[email protected]>
Date: 2015-08-24T07:07:32Z
Added time zone pattern
commit c12cb11e8d1b11de64e2657f2e444b4a47f037e5
Author: Alberto Rodriguez <[email protected]>
Date: 2015-08-24T07:08:00Z
Convert dates column types to proper Date object
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---