Github user shayshim commented on a diff in the pull request:

    https://github.com/apache/curator/pull/303#discussion_r251593572
  
    --- Diff: 
curator-client/src/main/java/org/apache/curator/utils/InjectSessionExpiration.java
 ---
    @@ -94,7 +89,7 @@ public static void injectSessionExpiration(ZooKeeper 
zooKeeper)
                 Object eventThread = eventThreadField.get(clientCnxn);
                 queueEventMethod.invoke(eventThread, event);
                 queueEventOfDeathMethod.invoke(eventThread);
    --- End diff --
    
    Why it is important to queue event of death immediately? It will be done 
for us soon by this flow:
    ConnectionState.process -> handleExpiredSession -> ... -> 
ClientCnxn.disconnect ->...
    - because we just queued this WatchedEvent.
    Same thing for wakeupCnxnMethod.invoke.


---

Reply via email to