Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(spill): Only use query config to decide prefix sort enable status #12340

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

zation99
Copy link
Contributor

Summary:
Right now we have two places for checking whether spill prefixsort is enabled:
1: QueryConfig::spillPrefixSortEnabled() that decides based on the worker config
2: SpillConfig::prefixSortEnabled() that decides based on prefixSortConfig.has_value()

2 depends on 1 based on the assumption that if 1 is false, prefixSortConfig is nullopt, and this is done through
DriverCtx::makeSpillConfig()

It's better that we only have one source of truth instead of two: checking the worker config. Because the dependency logic is not immediately obvious and may easily break in the future without notice.

Differential Revision: D69678186

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Feb 14, 2025
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D69678186

Copy link

netlify bot commented Feb 14, 2025

Deploy Preview for meta-velox canceled.

Name Link
🔨 Latest commit df64c7e
🔍 Latest deploy log https://app.netlify.com/sites/meta-velox/deploys/67afc5b84b56510008d5ae6d

@zation99 zation99 changed the title Only use query config to decide prefix sort enable status refactor: Only use query config to decide prefix sort enable status Feb 14, 2025
@zation99 zation99 changed the title refactor: Only use query config to decide prefix sort enable status refactor(spill): Only use query config to decide prefix sort enable status Feb 14, 2025
…cubator#12340)

Summary:

Right now we have two places for checking whether spill prefixsort is enabled:
1: `QueryConfig::spillPrefixSortEnabled()` that decides based on the worker config
2: `SpillConfig::prefixSortEnabled()` that decides based on `prefixSortConfig.has_value()`


2 depends on 1 based on the assumption that if 1 is false, `prefixSortConfig` is `nullopt`, and this is done through
`DriverCtx::makeSpillConfig()`

It's better that we only have one source of truth instead of two: checking the worker config. Because the dependency logic is not immediately obvious and may easily break in the future without notice.

Differential Revision: D69678186
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D69678186

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants