hadoop-common-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] (HADOOP-9159) FileSystem class should override .equals(Object)
Date Fri, 08 May 2015 21:51:02 GMT

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

Tsz Wo Nicholas Sze commented on HADOOP-9159:
---------------------------------------------

Why this is useful?  Applications could compare getCanonicalUri() if they want to.

Two different FileSystems with the same CanonicalUri may be associated with two different
UGIs.  So consider they are the same may lead to some unexpected behavior.

> FileSystem class should override .equals(Object)
> ------------------------------------------------
>
>                 Key: HADOOP-9159
>                 URL: https://issues.apache.org/jira/browse/HADOOP-9159
>             Project: Hadoop Common
>          Issue Type: Improvement
>          Components: fs
>    Affects Versions: 1.1.1, 3.0.0
>            Reporter: Thejas M Nair
>            Assignee: Brandon Li
>         Attachments: HADOOP-9159.patch, HADOOP-9159.patch
>
>
> The FileSystem class has a notion of equality, based on the uri. The class should override
.equal(Object) so that it returns true if FileSystem objects are logically same. 
> This is useful when FileSystem cache is disabled, as FileSystem.get(..) will return new
object each time.



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

Mime
View raw message