SHAFT


Serializable, Highly Available, and Fault-tolerant Transactions

----A new distributed concurrency control protocol for efficiently achieving serializability, high availability, and fault tolerancy in databases across data centers.

What is SHAFT

SHAFT is a new distributed concurrency control protocol, which guarantees serializability, high availability and fault tolerance simultaneously for transactions in databases across data centers.It implements strict two-phase locking in the distributed environment, and with the fault-tolerance guarantee. The SHAFT protocol can be implemented in any system that partitions, distributes and replicates data in a large scale. Even if the partition, the distribution and the replication is not uniform, e.g. not full replica in a datacenter or datacenters with different partition sets, our proposal is also feasible.

Motivation

Transaction support is a very valuable feature for database-backed applications. The lack of strong consistency semantics, e.g. transaction support, can lead to great difficulty of application development. Among all isolation levels, serializability is the most desirable one by applications. On the other hand, high availability and fault-tolerance are two important properties of systems in the cloud. Thus, it is desirable to have transaction support with serializability, high availability and fault-tolerance guarantees simultaneously.

Key Idea

To achieve high availability and fault tolerance, we exploit the Paxos algorithm as the basis. However, we incarnate the roles of the Paxos algorithm differently from other proposals, including the leader election and the configuration determination. We also update the operation semantics of the Paxos algorithm, such that a Paxos-based distributed two phase locking procedure is implemented to guarantee serializability. The updated operation semantics include consensus and majority. SHAFT allows a client to actively abort its submitted transaction by using two Paxos instances. If the user never aborts a transaction after initiation as in MDCC or for read-only transactions, SHAFT requires only one Paxos instance.

Implementation

We implement SHAFT protocol in the large-scale network simulator PeerSim. We use the event-based framework. We also implement multiple controls to simulate different system conditions, e.g. various multi-datacenter scenarios, node and datacenter failures, workloads, replication strategies, etc.

The work of SHAFT is supported by the National Natural Science Foundation of China (Grant No.61303054).

SHAFT implementation is now available for free downloads. Involved software components are governed by their own licensing terms. Users intending to use SHAFT are required to fully understand abide by the licensing terms of the involving components.

If you want to try or use SHAFT, you can click the following link to download the implementation.

SHAFT over PeerSim

SHAFT: Serializable, Highly Available and Fault Tolerant Concurrency Control in the Cloud [PDF]

In Proc. of ICPADS 2015.

SHAFT was developed in the Advanced Computer System Lab at Institute of Computing Technology, Chinese Academy of Sciences. Read our SHAFT papers or download our SHAFT protocol simulation implementation , if you are interested in more details. If you have any comments or questions, feel free to email us at: zhuyuqing@ict.ac.cn.

  • SHAFT proposal finalized (2013-07-21)
  • SHAFT webpage online (2013-08-19)
  • SHAFT technical report and sources open for downloads (2013-08-20)