virajjasani opened a new pull request, #5407:
URL: https://github.com/apache/hadoop/pull/5407

   With [HADOOP-18628](https://issues.apache.org/jira/browse/HADOOP-18628) in 
place, we perform InetAddress#getHostName in addition to 
InetAddress#getHostAddress, to save host name with IPC Connection object. When 
we perform InetAddress#getHostName, toString() of InetAddress would 
automatically print {hostName}/{hostIPAddress} if hostname is already resolved:
   
   ```
   /**
    * Converts this IP address to a {@code String}. The
    * string returned is of the form: hostname / literal IP
    * address.
    *
    * If the host name is unresolved, no reverse name service lookup
    * is performed. The hostname part will be represented by an empty string.
    *
    * @return  a string representation of this IP address.
    */
   public String toString() {
       String hostName = holder().getHostName();
       return ((hostName != null) ? hostName : "")
           + "/" + getHostAddress();
   }
   ```
   
   For namenode audit logs, this means that when dfs client makes filesystem 
updates, the audit logs would also print host name in the audit logs in 
addition to ip address. We have some tests that performs regex pattern matching 
to identify the log pattern of audit logs, we will have to change them to 
reflect the change in host address.


-- 
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]

Reply via email to