Correct option is B
1. Statement I:
· Conservative Two-Phase Locking (2PL) is a deadlock-free protocol because it ensures that a transaction acquires all the required locks before it starts executing.
· By pre-acquiring all locks, it avoids circular wait conditions, which are a primary cause of deadlock.
· Hence, Statement I is true.
2. Statement II:
· Thomas's Write Rule does not enforce conflict serializability.
· Instead, it is used in timestamp ordering protocols to optimize the schedule by ignoring outdated writes that would not affect the final result of the transactions.
· Conflict serializability requires stricter constraints, which Thomas's write rule does not always adhere to.
· Hence, Statement II is false.
3. Statement III:
· The timestamp ordering protocol ensures serializability by ordering transactions based on their timestamps.
· This protocol ensures that if a transaction Ti has a lower timestamp than Tj, then Ti appears before Tj in the serial order.
· Hence, Statement III is true.
Information Booster:
1. Conservative 2PL:
· Requires all locks to be acquired before a transaction starts.
· Prevents deadlocks but may reduce concurrency.
2. Thomas's Write Rule:
· Allows optimization in timestamp ordering by skipping outdated writes.
· Helps reduce the overhead of aborting transactions.
3. Timestamp Ordering Protocol:
· Ensures that conflicting operations are executed in the order of their timestamps.
· Guarantees serializability.
4. Two-Phase Locking (2PL):
· Ensures conflict serializability by dividing the transaction into two phases:
· Growing phase: Acquiring locks.
· Shrinking phase: Releasing locks.
Additional Knowledge:
· Deadlock Prevention: Techniques like Conservative 2PL and Wait-Die/Wound-Wait schemes are used to prevent deadlocks.
· Conflict Serializability: Ensures that the schedule is equivalent to some serial schedule.
· Timestamp-Based Scheduling: Ensures a serial order of transactions based on timestamps, often used in distributed databases.