atomically updating multiple keys
tuure.laurinolli at portalify.com
Wed Nov 2 08:01:47 EDT 2011
On Nov 1, 2011, at 19:23 , Justin Karneges wrote:
> On Tuesday, November 01, 2011 05:16:43 AM Tuure Laurinolli wrote:
>> Yes, you would get causal consistency with N=3, R=2, W=2. If client A,
>> using some side channel, tells client B that it inserted something, it is
>> guaranteed that client B can read it.
> Okay, good, this is how I understood it.
> I am curious now though how R > 1 works under the hood. Suppose we've got the
> above configuration (N=3, R=2, W=2) with server nodes X, Y, Z. If client A
> writes to X and Y, and then, before the data propogates to Z, client B reads
> from Y and Z, shouldn't the read operation fail because Y and Z don't agree on
> the same value? Or is it enough that Y has the latest value and this trumps
> whatever was returned from Z? I'd think it must be the latter behavior for
> causal consistency to work.
Yes, latest value read wins.
More information about the riak-users