



Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!




1
Ling Liu Associate Professor College of Computing, Georgia Tech
DB
Æ Two Phase Locking (2PL) (Binary Locks + Share and Exclusive Locks) Æ S/X locks with Increment Lock, Update Lock Æ Multiple Granularity Locks (IS, IX, SIX …) Æ Phantoms Phenomenon Æ Tree-based CC Æ Validation CC
Æ Recoverable Schedule Æ Avoid cascading rollback + Strict Schedule Æ Nested Transactions Æ View Serializability
3
Chapters to Read:
z skim 9.
z Read 10.1, 10.2, 10. z skim 10.4, 10.5, 10.6, 10.
DB
Locking Schemes
7
Deadlock Avoidance: Conservative 2 PL
Conservative 2 PL (static) : requires a transaction T to
Obtain lock Release lock
BEGIN END
Transaction period of duration data item use
No. of locks
Phase 1 Phase 2
DB
Strict 2 PL In addition to the Basic 2 PL , and Conservative 2 PL , there is another version of 2 PL: Strict 2 PL :
Obtain lock Release lock
BEGIN (^) period of END Transactionduration data item use
No. of locks
Concurrency Control Methods
Locking Techniques for Concurrency Control Ensuring Serializability by Two-Phase Locking 2PL if every transaction in the schedule S satisfies the 2PL protocol, S is guaranteed to be serializable, Conservative 2PL –Deadlock free strict 2PL – recoverable Deaklocks