Skip to content

[Backport] topn with granularity regression fixes#17580

Merged
cryptoe merged 2 commits intoapache:31.0.1from
clintropolis:backport-17565-to-31.0.1
Dec 18, 2024
Merged

[Backport] topn with granularity regression fixes#17580
cryptoe merged 2 commits intoapache:31.0.1from
clintropolis:backport-17565-to-31.0.1

Conversation

@clintropolis
Copy link
Copy Markdown
Member

Backport of #17565 to 31.0.1.

* topn with granularity regression fixes

changes:
* fix issue where topN with query granularity other than ALL would use the heap algorithm when it was actual able to use the pooled algorithm, and incorrectly used the pool algorithm in cases where it must use the heap algorithm, a regression from apache#16533
* fix issue where topN with query granularity other than ALL could incorrectly process values in the wrong time bucket, another regression from apache#16533

* move defensive check outside of loop

* more test

* extra layer of safety

* move check outside of loop

* fix spelling

* add query context parameter to allow using pooled algorithm for topN when multi-passes is required even wihen query granularity is not all

* add comment, revert IT context changes and add new context flag
@clintropolis clintropolis added this to the 31.0.1 milestone Dec 17, 2024
@cryptoe cryptoe merged commit ca13a30 into apache:31.0.1 Dec 18, 2024
@clintropolis clintropolis deleted the backport-17565-to-31.0.1 branch December 18, 2024 09:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants