Serializable Isolation


Last Updated on Mar 03, 2021

The best form of Isolation guarantee that a database can offer is Serializability, where each transaction can pretend that it is the only transaction running on the entire database. The database ensures that the result is the same as if the transactions had run serially when they have committed.

If transactions were executed one at a time, we would completely sidestep the problem of detecting and avoiding concurrency conflicts. However, this mode has become feasible only recently, with improvements in RAM size (to load the entire database into memory) and the understanding that OLTP transactions are typically small.

Most databases implement serializability in one of three ways:

In practice, however, serializable isolation is rarely used because of performance issues. Implementations of serializability either do not perform well (Two-phase locking) or don't scale well. Still, a database could use serializable isolation for OLTP transactions but switch to weaker isolation modes for long-running queries.


© 2022 Ambitious Systems. All Rights Reserved.