shuwenwei opened a new pull request, #18807: URL: https://github.com/apache/iotdb/pull/18807
## Description Disk usage statistics acquire a resource read lock when collecting files and acquire another when registering a reader reference for scanning. After scanning, only one lock is released and the file is removed from the cleanup queue, leaving a read lock held even after the statistics utility is closed. Register one `FileReaderManager` reference when collecting each closed file, and consistently release it through `decreaseFileReaderReference()` when skipping a file, finishing a scan, or cleaning up remaining files. Remove the duplicate reference registration before scanning. This balances reader references and resource read locks for both tree-model and table-model disk usage statistics. ## Validation - [x] Self-reviewed acquisition, skipped-file, scan success/failure, and cleanup paths against the current `FileReaderManager` implementation. - Tests were not run. ##### Key changed classes - `DiskUsageStatisticUtil` -- 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]
