smengcl commented on code in PR #10687:
URL: https://github.com/apache/ozone/pull/10687#discussion_r3715286037
##########
hadoop-hdds/framework/src/main/java/org/apache/hadoop/hdds/utils/HddsServerUtil.java:
##########
@@ -189,13 +184,11 @@ public static List<InetAddress>
getValidInetsForCurrentHost()
while (enumAdds.hasMoreElements()) {
InetAddress addr = enumAdds.nextElement();
- String hostAddress = addr.getHostAddress();
- if (!INVALID_IPS.contains(hostAddress) &&
ipValidator.isValid(hostAddress)
Review Comment:
Yes. `NetworkInterface#getInetAddresses` returns addresses that are already
valid `InetAddress` objects. Because it returns `InetAddress` objects for IP
addresses bound to the interface.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]