Skip to content

[Backport] Process pure ordering changes with windowing operators (#15241)#15275

Merged
LakshSingla merged 1 commit intoapache:28.0.0from
kgyrtkirk:scan-and-sort-28
Oct 30, 2023
Merged

[Backport] Process pure ordering changes with windowing operators (#15241)#15275
LakshSingla merged 1 commit intoapache:28.0.0from
kgyrtkirk:scan-and-sort-28

Conversation

@kgyrtkirk
Copy link
Copy Markdown
Member

  • adds a new query build path: DruidQuery#toScanAndSortQuery which:
  • builds a ScanQuery without considering the current ordering
  • builds an operator to execute the sort
  • fixes a null string to "null" literal string conversion in the frame serializer code
  • fixes some DrillWindowQueryTest cases
  • fix NPE in NaiveSortOperator in case there was no input
  • enables back CoreRules.AGGREGATE_REMOVE
  • adds a processing level OffsetLimit class and uses that instead of just the limit in the rac parts
  • earlier window expressions on top of a subquery with an offset may have ignored the offset

(cherry picked from commit f4a7471)

Fixes #XXXX.

Description

Fixed the bug ...

Renamed the class ...

Added a forbidden-apis entry ...

Release note


Key changed/added classes in this PR
  • MyFoo
  • OurBar
  • TheirBaz

This PR has:

  • been self-reviewed.
  • added documentation for new or modified features or behaviors.
  • a release note entry in the PR description.
  • added Javadocs for most classes and all non-trivial methods. Linked related entities via Javadoc links.
  • added or updated version, license, or notice information in licenses.yaml
  • added comments explaining the "why" and the intent of the code wherever would not be obvious for an unfamiliar reader.
  • added unit tests or modified existing tests to cover new code paths, ensuring the threshold for code coverage is met.
  • added integration tests.
  • been tested in a test Druid cluster.

- adds a new query build path: DruidQuery#toScanAndSortQuery which:
- builds a ScanQuery without considering the current ordering
- builds an operator to execute the sort
- fixes a null string to "null" literal string conversion in the frame serializer code
- fixes some DrillWindowQueryTest cases
- fix NPE in NaiveSortOperator in case there was no input
- enables back CoreRules.AGGREGATE_REMOVE
- adds a processing level OffsetLimit class and uses that instead of just the limit in the rac parts
- earlier window expressions on top of a subquery with an offset may have ignored the offset

(cherry picked from commit f4a7471)
@abhishekagarwal87 abhishekagarwal87 changed the title Process pure ordering changes with windowing operators (#15241) [Backport] Process pure ordering changes with windowing operators (#15241) Oct 30, 2023
@abhishekagarwal87 abhishekagarwal87 added this to the 28.0 milestone Oct 30, 2023
@LakshSingla LakshSingla merged commit d3fad8f into apache:28.0.0 Oct 30, 2023
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