Controlled lock violation

In databases with a large buffer pool, a transaction may run in less time than it takes to log the transaction's commit record on stable storage. Such cases motivate a technique called early lock release: immediately after appending its commit record to the log buffer in memory, a transaction may release its locks. Thus, it cuts overall lock duration to a fraction and reduces lock contention accordingly. Early lock release also has its problems. The initial mention of early lock release was incomplete, the first detailed description and implementation was incorrect with respect to read-only transactions, and the most recent design initially had errors and still does not cover unusual lock modes such as "increment" locks. Thus, we set out to achieve the same goals as early lock release but with a different, simpler, and more robust approach. The resulting technique, controlled lock violation, requires no new theory, applies to any lock mode, promises less implementation effort and slightly less run-time effort, and also optimizes distributed transactions, e.g., in systems that rely on multiple replicas for high availability and high reliability. In essence, controlled lock violation retains locks until the transaction is durable but permits other transactions to violate its locks while flushing its commit log record to stable storage.

[1]  Henry F. Korth,et al.  Locking Primitives in a Database System , 1983, JACM.

[2]  Irving L. Traiger,et al.  Granularity of Locks in a Large Shared Data Base. , 1975, VLDB 1975.

[3]  Michael Stonebraker,et al.  A measure of transaction processing power , 1985 .

[4]  Jason Flinn,et al.  Rethink the sync , 2006, OSDI '06.

[5]  Ippokratis Pandis,et al.  Improving OLTP Scalability using Speculative Lock Inheritance , 2009, Proc. VLDB Endow..

[6]  Goetz Graefe,et al.  A survey of B-tree locking techniques , 2010, TODS.

[7]  Jignesh M. Patel,et al.  High-Performance Concurrency Control Mechanisms for Main-Memory Databases , 2011, Proc. VLDB Endow..

[8]  Harumi A. Kuno,et al.  Efficient Locking Techniques for Databases on Modern Hardware , 2012, ADMS@VLDB.

[9]  Daniel J. Abadi,et al.  Calvin: fast distributed transactions for partitioned database systems , 2012, SIGMOD Conference.

[10]  Irving L. Traiger,et al.  Transactions and consistency in distributed database systems , 1982, TODS.

[11]  Eljas Soisalon-Soininen,et al.  Partial Strictness in Two-Phase Locking , 1995, ICDT.

[12]  Goetz Graefe,et al.  Foster b-trees , 2012, TODS.

[13]  Tim Kraska,et al.  MDCC: multi-data center consistency , 2012, EuroSys '13.

[14]  Ippokratis Pandis,et al.  Aether: A Scalable Approach to Logging , 2010, Proc. VLDB Endow..

[15]  Babak Falsafi,et al.  Shore-MT: a scalable storage manager for the multicore era , 2009, EDBT '09.

[16]  Michael Stonebraker,et al.  The Performance of Concurrency Control Algorithms for Database Management Systems , 1984, VLDB.

[17]  Irving L. Traiger,et al.  Granularity of Locks and Degrees of Consistency in a Shared Data Base , 1998, IFIP Working Conference on Modelling in Data Base Management Systems.

[18]  Ouri Wolfson An Algorithm for Early Unlocking of Entities in Database Transactions , 1986, J. Algorithms.

[19]  Irving L. Traiger,et al.  Granularity of locks in a shared data base , 1975, VLDB '75.

[20]  Michael Stonebraker,et al.  Implementation techniques for main memory database systems , 1984, SIGMOD '84.