A Survey of Approaches to Database Replication
F. D. Muñoz-Escoí (Universidad Politécnica de Valencia, Spain), H. Decker (Universidad Politécnica de Valencia, Spain), J. E. Armendáriz (Universidad Politécnica de Valencia, Spain) and J. R. González de Mendívil (Universidad Politécnica de Valencia, Spain)
Copyright: © 2009
Databases are replicated in order to get two complementary features: performance improvement and high availability. Performance can be improved when a database is replicated since each replica can serve read-only accesses without requiring any coordination with the rest of replicas. Thus, when most of the application accesses to the data are read-only, they can be served locally and without preventing accesses in the same or other replicas. Moreover, with a careful management, the failure of one or more replicas does not compromise the availability of the database.
In the active replication technique, the client initially submits a transaction request to one of the replicas. Such delegate replica broadcasts the request to all replicas and all of them process the transaction from its start. Note that different transactions can use different delegate replicas. This technique requires complete determinism in the execution of a transaction, since otherwise the resulting state could be different among replicas. In order to easily develop this model, transactions can be implemented as stored procedures. Note that all transaction operations or parameters should be known before such transaction is started, being propagated in its starting broadcast.
Key Terms in this Chapter
Writeset: The set of data items written by a given transaction.
Secondary Replica: In the passive replication model, or primary copy technique, all non-primary replicas are also known as secondary replicas. Such replicas can not accept user transactions, and only behave as backup copies of the primary one.
Readset: The set of data items read by a given transaction.
Delegate Replica: In replication models that do not follow the primary copy technique, the delegate replica directly processes a transaction, generating the updates that later will be transmitted to the other replicas. Different transactions can use different delegate replicas.
Reliable Broadcast: One that requires that all correct processes deliver the same set of messages, and such a set includes all messages broadcast by correct processes, and no spurious messages.
Total Order Broadcast: One that requires that all correct processes deliver all messages in the same order; i.e., a reliable broadcast with total order.
Primary Replica: In the passive replication model, or primary copy technique, the single replica that is able to directly manage all database transactions.