mrhhsg opened a new pull request, #66328:
URL: https://github.com/apache/doris/pull/66328

   ### What problem does this PR solve?
   
   Issue Number: None
   
   Problem Summary:
   
   Spill file cleanup removed each operator-level directory but left its empty 
per-query parent under the active spill root. Long-running backends could 
therefore accumulate one directory inode for every query that wrote spill data.
   
   This change:
   
   - removes the empty query directory with non-recursive `rmdir` semantics 
after spill-file cleanup;
   - keeps sibling spill files safe by treating a non-empty query directory as 
the expected case;
   - serializes lazy spill-directory creation with empty parent removal, 
avoiding a parent `rmdir` versus recursive child `mkdir` race;
   - fixes the stale cleanup comment that referred to a removed query-context 
fallback.
   
   ### Release note
   
   Remove empty per-query spill directories after their spill files are cleaned 
up.
   
   ### Check List (For Author)
   
   - Test:
     - Unit Test: `./run-be-ut.sh --run 
--filter='SpillFileTest.GCCleansUpFiles:SpillFileTest.GCCleansUpEmptyQueryDirectoryWithoutDeletingSibling:SpillFileTest.LazySpillFileRecreatesCleanedQueryDirectory'`
   - Behavior changed: Yes. Empty temporary query directories under the active 
spill root are removed after the last spill file is cleaned up.
   - Does this need documentation: No
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to