nodece commented on PR #4588:
URL: https://github.com/apache/bookkeeper/pull/4588#issuecomment-2820056238

   > There is nothing wrong with the code, but it is recommended to add a 
testcase to cover this fix @nodece
   
   @StevenLuMT Although the existing tests can cover these changes, if the 
`java.net.InetAddress#getCanonicalHostName` cannot resolve the IP address to 
the hostname, which returns the IP address, we should avoid this case.
   
   > Gets the fully qualified domain name for this IP address. Best effort 
method, meaning we may not be able to return the FQDN depending on the 
underlying system configuration.
   If there is a security manager, this method first calls its checkConnect 
method with the hostname and -1 as its arguments to see if the calling code is 
allowed to know the hostname for this IP address, i.e., to connect to the host. 
If the operation is not allowed, it will return the textual representation of 
the IP address.
   Returns:
   the fully qualified domain name for this IP address, or if the operation is 
not allowed by the security check, the textual representation of the IP address.
   
   So I submit https://github.com/apache/bookkeeper/pull/4595 to fix this, 
could you have a chance to review?


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

Reply via email to