Improvements to disabling spill for distinct and order by aggregations#16564
Merged
rschlussel merged 4 commits intoprestodb:masterfrom Aug 6, 2021
Merged
Conversation
pgupta2
reviewed
Aug 5, 2021
Contributor
There was a problem hiding this comment.
MAX_REVOCABLE_MEMORY_PER_NODE --> QUERY_MAX_REVOCABLE_MEMORY_PER_NODE
Comment on lines
393
to
394
Contributor
There was a problem hiding this comment.
Lets also remove hasDistinct() and hasOrderBy() methods in this class.
Simplify so that everything is using the same source to check if spill is enabled.
3af3bda to
cf54ee4
Compare
Add session property query_max_revocable_memory_per_node for the config property experimental.max-revocable-memory-per-node
spill_enabled is already set by config. Don't need session property also.
The session property we were using before to ensure spill wasn't being run wasn't actually enforcing a limit. Additionally, the distinct aggregation test wasn't spilling in the aggregation even with spill enabled because the aggregation would finish before spilling started. Finally, we needed to remove the final order by from the queries to prevent failures due to spilling the order by operator.
cf54ee4 to
fc88a8e
Compare
Contributor
Author
|
Thanks @pgupta2 for review. addressed your comments. |
pgupta2
approved these changes
Aug 5, 2021
arhimondr
approved these changes
Aug 6, 2021
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR fixes the test for ensuring that we don't spill with distinct/order by spill enabled and improves how we are disabling spill.
Test plan - unit tests