[jira] [Updated] (HADOOP-12295) Improve NetworkTopology#InnerNode#remove logic
[ https://issues.apache.org/jira/browse/HADOOP-12295?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Yi Liu updated HADOOP-12295: Resolution: Fixed Hadoop Flags: Reviewed Fix Version/s: 2.8.0 Status: Resolved (was: Patch Available) 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)
[jira] [Updated] (HADOOP-12295) Improve NetworkTopology#InnerNode#remove logic
[ https://issues.apache.org/jira/browse/HADOOP-12295?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Yi Liu updated HADOOP-12295: Description: In {{NetworkTopology#InnerNode#remove}}, We can use {{childrenMap}} to get the parent node, no need to loop the {{children}} list. Another nit in current code is: {code} String parent = n.getNetworkLocation(); String currentPath = getPath(this); {code} can be in closure of {{\!isAncestor\(n\)}} was:In {{NetworkTopology#InnerNode#remove}}, We can use {{childrenMap}} to get the parent node, no need to loop the {{children}} list. 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 In {{NetworkTopology#InnerNode#remove}}, We can use {{childrenMap}} to get the parent node, no need to loop the {{children}} list. 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)
[jira] [Updated] (HADOOP-12295) Improve NetworkTopology#InnerNode#remove logic
[ https://issues.apache.org/jira/browse/HADOOP-12295?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Yi Liu updated HADOOP-12295: Description: 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\)}} was: In {{NetworkTopology#InnerNode#remove}}, We can use {{childrenMap}} to get the parent node, no need to loop the {{children}} list. Another nit in current code is: {code} String parent = n.getNetworkLocation(); String currentPath = getPath(this); {code} can be in closure of {{\!isAncestor\(n\)}} 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 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)
[jira] [Updated] (HADOOP-12295) Improve NetworkTopology#InnerNode#remove logic
[ https://issues.apache.org/jira/browse/HADOOP-12295?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Yi Liu updated HADOOP-12295: Description: In {{NetworkTopology#InnerNode#remove}}, We can use {{childrenMap}} to get the parent node, no need to loop the {{children}} list. (was: In {{ NetworkTopology#InnerNode#remove}}, We can use {{childrenMap}} to get the parent node, no need to loop the {{children}} list.) 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 In {{NetworkTopology#InnerNode#remove}}, We can use {{childrenMap}} to get the parent node, no need to loop the {{children}} list. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (HADOOP-12295) Improve NetworkTopology#InnerNode#remove logic
[ https://issues.apache.org/jira/browse/HADOOP-12295?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Yi Liu updated HADOOP-12295: Attachment: HADOOP-12295.001.patch 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 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. 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)
[jira] [Updated] (HADOOP-12295) Improve NetworkTopology#InnerNode#remove logic
[ https://issues.apache.org/jira/browse/HADOOP-12295?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Yi Liu updated HADOOP-12295: Status: Patch Available (was: Open) 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 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)