jiajunwang commented on a change in pull request #642: Fix handleNewSession creating ephemeral node with expired session URL: https://github.com/apache/helix/pull/642#discussion_r361017925
########## File path: helix-core/src/main/java/org/apache/helix/manager/zk/client/HelixZkClient.java ########## @@ -172,6 +186,15 @@ void asyncSetData(final String path, Object datat, final int version, long getSessionId(); + /** + * Gets the zookeeper's session id of this zk client in hexadecimal notation. + * This session could be valid, expired, or "0"(initial value before zk session is established). + * Ex. 1000a5ceb930004 is returned. + * + * @return String representation of session id in hexadecimal notation. + */ + String getHexSessionId(); Review comment: FYI, I think we want to expose as little information as possible from this interface. We leave getSessionId mainly for backward compatibility. If there is no critical usage, please do not expose more internal session ID (which is changeable) to the ZkClient user. ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
