This paper studies the semantics of sets under eventual consistency. The set is a pervasive data type, used either directly or as a component of more complex data types, such as maps or graphs. Eventual consistency of replicated data supports concurrent updates, reduces latency and improves fault tolerance, but forgoes strong consistency (e.g., linearisability). Accordingly, several cloud computing platforms implement eventually-consistent replicated sets [2,4].The sequential semantics of a set are well known, and are defined by individual updates, e.g., {true}add(e){e ∈ S} (in "{pre-condition} computation {post-condition}" notation), where S denotes its abstract state. However, the semantics of concurrent modifications is left underspecified or implementationdriven.We propose the following Principle of Permutation Equivalence to express that concurrent behaviour conforms to the sequential specification: "If all sequential permutations of updates lead to equivalent states, then it should also hold that concurrent executions of the updates lead to equivalent states." It implies the following behavior, for some updates u and u :Specifically for replicated sets, the Principle of Permutation Equivalence requires that {e = f }add(e) remove(f ){e ∈ S ∧ f / ∈ S}, and similarly for operations on different elements or idempotent operations. Only the pair add(e) remove(e) is unspecified by the principle, since add(e); remove(e) differs from remove(e); add(e). Any of the following post-conditions ensures a deterministic result:{⊥e ∈ S} -Error mark {e ∈ S} -add wins {e / ∈ S} -remove wins {add(e) > CLK remove(e) ⇔ e ∈ S} -Last Writer Wins (LWW) where < CLK compares unique clocks associated with the operations. Note that
Convergent Replicated Data Types (CRDTs) can be used as basic building blocks for storing and managing replicated data in a distributed system. They provide high availability and performance, and they guarantee eventual consistency. In this paper, we develop a formal framework for the analysis and verification of CRDTs. We investigate and compare the three currently used specification techniques for CRDTs and formalize them based on an abstract model for managing replicated data in distributed systems. We show how CRDT implementations can be expressed in our framework and present a general strategy for verifying CRDTs. Finally, we report on our experiences in using the framework for the verification of important existing CRDT implementations. The framework and the proofs were developed within the interactive theorem prover Isabelle/HOL.
scite is a Brooklyn-based organization that helps researchers better discover and understand research articles through Smart Citations–citations that display the context of the citation and describe whether the article provides supporting or contrasting evidence. scite is used by students and researchers from around the world and is funded in part by the National Science Foundation and the National Institute on Drug Abuse of the National Institutes of Health.