github-actions[bot] commented on code in PR #64224:
URL: https://github.com/apache/doris/pull/64224#discussion_r3394580156


##########
fs_brokers/apache_hdfs_broker/src/main/java/org/apache/doris/broker/hdfs/FileSystemManager.java:
##########
@@ -198,13 +216,12 @@ private static String preparePrincipal(String 
originalPrincipal) throws UnknownH
     /**
      * visible for test
      *
-     * @param path
-     * @param properties
+     * @param path the file path to be parsed (e.g., hdfs://...)
+     * @param properties the configuration properties for the file system
      * @return BrokerFileSystem with different FileSystem based on scheme
-     * @throws URISyntaxException
-     * @throws Exception

Review Comment:
   `updateCachedFileSystem()` now increments `activeOperationCount` for every 
successful acquisition, and the recycle cleanup refuses to close an evicted 
filesystem while that count is non-zero. This method is still 
public/visible-for-test, and existing direct callers such as 
`TestFileSystemManager.testGetFileSystemSuccess()` call `getFileSystem(...)` 
without any matching `decrementActiveOperations()`. If such a filesystem is 
later expired or moved to the recycle bin, 
`CheckBrokerFileSystemExpirationTask` will keep re-queueing it forever because 
the leaked operation count never reaches zero. Please either keep the operation 
reference accounting inside the higher-level broker operations only, or 
introduce a scoped/release API and update all direct 
`getFileSystem()`/scheme-specific getter callers to balance the acquisition.



-- 
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