zookeeper-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "bit1129@163.com" <bit1...@163.com>
Subject Does zookeeper guarantee read your write in consecutive sessions?
Date Fri, 14 Nov 2014 02:42:41 GMT
Hi,

Consider the following scenario:

ABCDE is the zookeeper ensemble,  ABC form the quorum.
The following sequence may happen:
1. Client writes the data, and ABC are updated, but DE haven't because of the network latency(say,
long enough for this scenario).
2. Client closes the session.
3. Client start a new session in the same thread, Is zookeeper guarantee the client to see
the previously data set in the above step(that is,  it will connect to A, B or C) or zookeeper
does NOT guarantee this(that is,it may connect to D or E which doesn't have the data set in
above steps)

I guess that Zookeeper doesn't guarantee  the client to see the data set in the first step
 because the two sessions are totally different ones to Zookeeper even they are created by
the same thread, and also because when the session is first created, there is no zxid information
that the server can be used to determine the client status.
Please correct me if I am wrong, thanks.




bit1129@163.com
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message