zookeeper-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Han <h...@apache.org>
Subject Re: Zookeeper consistency
Date Tue, 17 Jul 2018 18:42:37 GMT
>> I think that Zookeeper is linearable only if there are only write
operation.

Yes writes are linearizable because writes are totally ordered globally.

For read, a linearizable read needs to read the latest writes in the system
at the point in time the read is issued; so by this definition, ZK read is
not linearizable, even with sync+read as both are separate operations. If
we provide a quorum read (so read operations are broadcasted globally as
well), then the read will be linearizable as well, but no practical systems
would do that due to performance reasons.


On Tue, Jul 17, 2018 at 3:13 AM, chen dongming <cademfly@hotmail.com> wrote:

> hi,
>
> I am reading the old thread of
> http://comments.gmane.org/gmane.comp.java.hadoop.zookeeper.user/5221.
>
> I have 2 questions.
>
>
> Question 1:
>
> I agree with Zookeeper is sequential consistency, but I don't think
> Zookeeper is linearizability even if doing sync+read for every read.
> for example,
>
> timeline ------------>
>
> C1:                sync()                  r1(x)
>
> C2: w2(x=1)             w2(x=2)
>
> It is possible r1 return x=1.  This history is not linearable according
> to Herlihy difination.
>
>
> Question 2:
>
> I think that Zookeeper is linearable only if there are only write
> operation.
>
>
> Dominic,
>
> Best Regard.
>
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message