hadoop-hdfs-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Joe Pallas (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HDFS-7758) Retire FsDatasetSpi#getVolumes() and use FsDatasetSpi#getVolumeRefs() instead
Date Sat, 07 Mar 2015 00:59:40 GMT

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

Joe Pallas commented on HDFS-7758:
----------------------------------

[~cmccabe], is findbugs actually smart enough to figure out that an iterator is {{Closeable}}
at call sites, which only see the {{Iterator}} interface?  Or would you need to define a new
interface that extends both {{Iterator}} and {{Closable}}?

> Retire FsDatasetSpi#getVolumes() and use FsDatasetSpi#getVolumeRefs() instead
> -----------------------------------------------------------------------------
>
>                 Key: HDFS-7758
>                 URL: https://issues.apache.org/jira/browse/HDFS-7758
>             Project: Hadoop HDFS
>          Issue Type: Improvement
>          Components: datanode
>    Affects Versions: 2.6.0
>            Reporter: Lei (Eddy) Xu
>            Assignee: Lei (Eddy) Xu
>         Attachments: HDFS-7758.000.patch, HDFS-7758.001.patch
>
>
> HDFS-7496 introduced reference-counting  the volume instances being used to prevent race
condition when hot swapping a volume.
> However, {{FsDatasetSpi#getVolumes()}} can still leak the volume instance without increasing
its reference count. In this JIRA, we retire the {{FsDatasetSpi#getVolumes()}} and propose
{{FsDatasetSpi#getVolumeRefs()}} and etc. method to access {{FsVolume}}. Thus it makes sure
that the consumer of {{FsVolume}} always has correct reference count.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message