Skip to content

limit max disk usage for spilling queries #15358

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

Closed
Tracked by #15271
alamb opened this issue Mar 22, 2025 · 0 comments · Fixed by #15520
Closed
Tracked by #15271

limit max disk usage for spilling queries #15358

alamb opened this issue Mar 22, 2025 · 0 comments · Fixed by #15520
Assignees
Labels
enhancement New feature or request

Comments

@alamb
Copy link
Contributor

alamb commented Mar 22, 2025

Is your feature request related to a problem or challenge?

Breaking rationale from #14975 (comment) into its own ticket:

For memory-limit queries, executors might write temporary results into the disk to reduce memory load. It's important to have a configuration option to limit the max disk usage, in case some query would bloat the disk and cause other issues.

DuckDB provides a similar configuration:

max_temp_directory_size | The maximum amount of data stored inside the 'temp_directory' (when set) (e.g., 1GB)

Describe the solution you'd like

Provide a way to limit the total disk usage of queries that spill to disk

Describe alternatives you've considered

Add a configuration option max_temp_directory_size to disk manager (default to 100GB), if the limit is reached for all spilled files, an error will be returned.

Additional context

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
2 participants