snmvaughan commented on code in PR #4725:
URL: https://github.com/apache/hadoop/pull/4725#discussion_r944566254
##########
hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/qjournal/client/IPCLoggerChannel.java:
##########
@@ -599,7 +599,12 @@ public ListenableFuture<Long> getJournalCTime() {
@Override
public String toString() {
- return InetAddresses.toAddrString(addr.getAddress()) + ':' +
addr.getPort();
+ if (addr.isUnresolved()) {
+ return addr.getHostName() + ":" + addr.getPort();
Review Comment:
This returns cached values. This change is only introduced to allow string
formatting to occur when the address is unresolved (instead of throwing an NPE).
--
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]