Uh oh!
There was an error while loading. Please reload this page.
branch-4.1: [fix](be) Clean up spill directories during query teardown - #66458
Conversation
Backport the spill-directory cleanup from apache#66328: - record each spill data root before opening the first spill part; - delete touched per-query spill directories during QueryContext teardown; - retain failed deletions and retry them from spill GC and shutdown paths; - keep no-spill queries on the zero-cleanup fast path. The recursive CTE and FragmentMgr lifecycle changes from the original PR are intentionally excluded because branch-4.1 has divergent recursive CTE code. Spill cleanup for that lifecycle remains out of scope. (cherry picked from commit 3dff55a)
hello-stephen
commented
Aug 5, 2026
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
mrhhsg
commented
Aug 5, 2026
run buildall |
mrhhsg
commented
Aug 5, 2026
run buildall |
hello-stephen
commented
Aug 5, 2026
BE UT Coverage ReportIncrement line coverage Increment coverage report
|
hello-stephen
commented
Aug 5, 2026
BE Regression && UT Coverage ReportIncrement line coverage Increment coverage report
|
hello-stephen
commented
Aug 5, 2026
BE Regression && UT Coverage ReportIncrement line coverage Increment coverage report
|
mrhhsg
commented
Aug 6, 2026
/review |
Codex automated review failed and did not complete. Error: All Codex review accounts are usage-limited; earliest retry is 2026-08-08T03:32:00Z. Please trigger /review again after that time. |
What problem does this PR solve?
Issue Number: None
Related PR: #66328
Problem Summary:
Backport the spill query-directory cleanup from #66328 to
branch-4.1.This change:
QueryContextteardown;The recursive CTE and
FragmentMgrlifecycle changes from the original PR are intentionally excluded because thebranch-4.1implementation diverges. Spill cleanup for query contexts retained by that lifecycle remains out of scope for this backport.Release note
None
Check List (For Author)
Test
./build.sh --be --fesucceeded.doris-local-regression run -d spill_p0 -s test_spill_directory_cleanup(1/1 passed, then rerun 1/1 passed).spill_disk_has_spill_datatransition from0to1and back to0after query cleanup.doris_be_testtarget compiled and linked successfully../run-be-ut.sh --run --filter='SpillFileTest.GCCleansUpFiles:SpillFileTest.QueryContextDeletesEmptySpillDirectory:SpillFileTest.QueryContextCleansUpNestedSpillDirectory:SpillFileTest.QueryContextDeletesResidualSpillDirectory:SpillFileTest.QueryContextCleansUpAllTouchedSpillDirectories:SpillFileTest.QueryContextContinuesCleanupAfterRootFailure:SpillFileTest.QueryContextRetriesSpillDirectoryDeletionUntilSuccess:SpillFileTest.RetryPreservesDirectoryQueuedAfterPendingDrain:SpillFileTest.QueryContextSkipsCleanupWithoutSpill:SpillFileTest.DeleteSpillFileThroughManagerSynchronously' -j 64(10/10 passed, then rerun 10/10 passed)build-support/check-format.sh(passed)git diff --check(passed)Behavior changed:
Does this need documentation?
Check List (For Reviewer who merge this PR)