You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-issues@hadoop.apache.org by "Tsz Wo Nicholas Sze (JIRA)" <ji...@apache.org> on 2015/10/28 07:20:27 UTC
[jira] [Commented] (HADOOP-12523) In FileSystem.Cache, the closeAll
methods should not synchronize on the Cache object
[ https://issues.apache.org/jira/browse/HADOOP-12523?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14977828#comment-14977828 ]
Tsz Wo Nicholas Sze commented on HADOOP-12523:
----------------------------------------------
I suggest that the closeAll methods (1) acquire the lock, (2) generate a list of target FileSystem objects and remove them from the cache, (3) release the lock, and (4) close the FileSystem objects in the list.
> In FileSystem.Cache, the closeAll methods should not synchronize on the Cache object
> ------------------------------------------------------------------------------------
>
> Key: HADOOP-12523
> URL: https://issues.apache.org/jira/browse/HADOOP-12523
> Project: Hadoop Common
> Issue Type: Improvement
> Components: fs
> Reporter: Tsz Wo Nicholas Sze
> Assignee: Tsz Wo Nicholas Sze
>
> All the closeAll methods holds the Cache lock so that when one of the three closeAll methods is being called, a new FileSystem object has to wait for the Cache lock. The wait time can possible be long since closing a FileSystem can be slow.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)