Abstract

Many cloud-service applications have a middle tier organized as micro-services or actors. Such applications have small objects that are spread over many servers and communicate via message passing. Transactions in such an application are necessarily distributed. However, distributed transactions usually perform poorly in this environment, primarily because locks must be held until after the forced-writes of two-phase commit, which are slow in cloud storage systems. We present a new transaction protocol that avoids this blocking by releasing all of a transaction’s locks during phase one of two-phase commit, and by tracking commit dependencies to implement cascading abort. While a transaction T runs phase one, later conflicting transactions batch their updates. After T is prepared, the delayed batch can prepare, enabling a distributed form of group commit. We describe how to implement our protocol in an object-oriented runtime such as JVM or .NET. The performance measurements of our implementation in the Orleans actor framework show throughput up to 20x that of two-phase locking and two-phase commit.