hadoop-hdfs-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Arun C Murthy (JIRA)" <j...@apache.org>
Subject [jira] [Closed] (HDFS-2330) In NNStorage.java, IOExceptions of stream closures can mask root exceptions.
Date Thu, 11 Oct 2012 17:48:27 GMT

     [ https://issues.apache.org/jira/browse/HDFS-2330?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Arun C Murthy closed HDFS-2330.
-------------------------------

    
> In NNStorage.java, IOExceptions of stream closures  can mask root exceptions.
> -----------------------------------------------------------------------------
>
>                 Key: HDFS-2330
>                 URL: https://issues.apache.org/jira/browse/HDFS-2330
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>          Components: name-node
>    Affects Versions: 0.24.0
>            Reporter: Uma Maheswara Rao G
>            Assignee: Uma Maheswara Rao G
>             Fix For: 3.0.0, 2.0.2-alpha
>
>         Attachments: HDFS-2330.patch, HDFS-2330.patch
>
>
> In NNStorage.java:
>   There are many stream closures in finally block. 
>   There is a chance that they can mask the root exceptions.
> So, better to follow the pattern like below:
> {code}
>   try{
>      ............
>      ............
>      stream.close();
>      stream =null;
>    }
>    finally{
>      IOUtils.cleanup(LOG, stream);
>    }
> {code}

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

Mime
View raw message