hadoop-hdfs-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tsz Wo (Nicholas), SZE (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HDFS-3373) FileContext HDFS implementation can leak socket caches
Date Tue, 18 Sep 2012 04:14:08 GMT

    [ https://issues.apache.org/jira/browse/HDFS-3373?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13457589#comment-13457589

Tsz Wo (Nicholas), SZE commented on HDFS-3373:

Hi John, thanks for working on this.  Some comments on the patch:

- In SocketCache.getInstance(..),
-* If SocketCache is already initialized (i.e. isInitedOnce == true), then the parameters
c and e will be igored silently.  Would it be a problem?
-* If it throws IllegalStateException, should isInitedOnce not be set to true?
-* typo: "initialzied" => "initialized"

- In SocketCache.evictExpired(..),
-* remove "throws IOException" since it does not throw it.
-* remove synchronized(this) since it is already synchronized.

- In SocketCache, add createTime to SocketAndStreams and remove SocketProp.

- In SocketCache.put(..), move "Preconditions.checkNotNull(sock);" to the very beginning.

> FileContext HDFS implementation can leak socket caches
> ------------------------------------------------------
>                 Key: HDFS-3373
>                 URL: https://issues.apache.org/jira/browse/HDFS-3373
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: hdfs client
>    Affects Versions: 2.0.0-alpha, 3.0.0
>            Reporter: Todd Lipcon
>            Assignee: John George
>         Attachments: HDFS-3373.branch-23.patch, HDFS-3373.trunk.patch, HDFS-3373.trunk.patch.1
> As noted by Nicholas in HDFS-3359, FileContext doesn't have a close() method, and thus
never calls DFSClient.close(). This means that, until finalizers run, DFSClient will hold
on to its SocketCache object and potentially have a lot of outstanding sockets/fds held on

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

View raw message