Skip to content

[Backport] fix timewarp query results when using timezones and crossing DST tran…#5252

Merged
leventov merged 2 commits intoapache:0.12.0from
jon-wei:backport-5157-to-0.12.0
Jan 12, 2018
Merged

[Backport] fix timewarp query results when using timezones and crossing DST tran…#5252
leventov merged 2 commits intoapache:0.12.0from
jon-wei:backport-5157-to-0.12.0

Conversation

@jon-wei
Copy link
Copy Markdown
Contributor

@jon-wei jon-wei commented Jan 11, 2018

Backport of #5157 to 0.12.0

…sitions (apache#5157)

* timewarp and timezones
changes:
* `TimewarpOperator` will now compensate for daylight savings time shifts between date translation ranges for queries using a `PeriodGranularity` with a timezone defined
* introduces a new abstract query type `TimeBucketedQuery` for all queries which have a `Granularity` (100% not attached to this name). `GroupByQuery`, `SearchQuery`, `SelectQuery`, `TimeseriesQuery`, and `TopNQuery` all extend `TimeBucke
tedQuery`, cutting down on some duplicate code and providing a mechanism for `TimewarpOperator` (and anything else) that needs to be aware of granularity

* move precondition check to TimeBucketedQuery, add Granularities.nullToAll, add getTimezone to TimeBucketQuery

* formatting

* more formatting

* unused import

* changes:
* add 'getGranularity' and 'getTimezone' to 'Query' interface
* merge 'TimeBucketedQuery' into 'BaseQuery'
* fixup tests from resulting serialization changes

* dedupe

* fix after merge

* suppress warning
@leventov leventov merged commit 87a1170 into apache:0.12.0 Jan 12, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants