Details
-
Improvement
-
Status: Resolved
-
Low
-
Resolution: Not A Problem
-
None
-
None
Description
In CASSANDRA-6504 the global shards still follow the
pattern of the legacy shards. We could store the
{increments, decrements}tuple in the shard instead, and for reconcile, instead of relying on the logical clock, pick the largest value of `increments` and `decrements` of the two shards, and use that.
E.g., shard1:
{2000, 1001}(total 999), shard2:
{2001, 1000}(total 1001). reconciled =
{max(2000, 2001), max(1001, 1000)}=
{2001, 1001}(total 1000).
While scenarios like this generally shouldn't happen post CASSANDRA-6504, this change costs us nothing, and makes issues like CASSANDRA-4417 theoretically impossible . This also makes our new implementation directly follow the http://hal.inria.fr/docs/00/55/55/88/PDF/techreport.pdf white paper.