Yeah, I mean the leader has expired Alice's session. Is there some time interval (some function of session timeout) that would ensure Alice gets 'false'?
-Nathan -----Original Message----- From: Flavio Junqueira [mailto:[email protected]] Sent: Monday, February 22, 2016 5:47 PM To: [email protected] Subject: Re: Clarification on ZooKeeper.getState().isAlive() and ephemeral nodes The ensemble leader is responsible for expiring sessions. If in step 3 you mean that the leader has expired Alice's session, then it might be the case that Alice doesn't know yet by step 5. However, if step 3 means that Alice has already been notified of the state change, then it will be false. -Flavio > On 22 Feb 2016, at 19:27, Nathan Yu <[email protected]> wrote: > > Say I have two clients, Alice and Bob > > 1. Alice creates ephemeral node /foo > 2. Bob sees ephemeral node /foo > 3. Alice's session expires. > 4. Bob sees ephemeral /foo disappear. > 5. Alice checks ZooKeeper.getState().isAlive() > > Is there a guarantee that Alice's ZooKeeper.getState().isAlive() will always > return false at step 5?
