hadoop-common-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hudson (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HADOOP-12295) Improve NetworkTopology#InnerNode#remove logic
Date Thu, 13 Aug 2015 16:13:49 GMT

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

Hudson commented on HADOOP-12295:
---------------------------------

FAILURE: Integrated in Hadoop-Hdfs-trunk-Java8 #275 (See [https://builds.apache.org/job/Hadoop-Hdfs-trunk-Java8/275/])
HADOOP-12295. Improve NetworkTopology#InnerNode#remove logic. (yliu) (yliu: rev 53bef9c5b98dee87d4ffaf35415bc38e2f876ed8)
* hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/net/NetworkTopology.java
* hadoop-common-project/hadoop-common/CHANGES.txt
* hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/net/TestNetworkTopology.java


> Improve NetworkTopology#InnerNode#remove logic
> ----------------------------------------------
>
>                 Key: HADOOP-12295
>                 URL: https://issues.apache.org/jira/browse/HADOOP-12295
>             Project: Hadoop Common
>          Issue Type: Improvement
>            Reporter: Yi Liu
>            Assignee: Yi Liu
>             Fix For: 2.8.0
>
>         Attachments: HADOOP-12295.001.patch
>
>
> In {{NetworkTopology#InnerNode#remove}}, We can use {{childrenMap}} to get the parent
node, no need to loop the {{children}} list. Then it is more efficient since in most cases
deleting parent node doesn't happen.
> Another nit in current code is:
> {code}
>   String parent = n.getNetworkLocation();
>   String currentPath = getPath(this);
> {code}
> can be in closure of {{\!isAncestor\(n\)}}



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

Mime
View raw message