CS 357: Database Systems Implementation
Homework Assignment 5 -- Concurrency Control


Given: Friday, 22 February
Due Date: Friday, 29 February


SimpleDB currently uses timeout to detect deadlock.  Change it so that it uses the wait-die deadlock detection strategy.  Your code should modify the class LockTable as follows:  

You will also need to modify other classes that use LockTable.   I'm sure you can figure out what those changes must be.

You must also write a test program.  The program should generate at least three threads (as in Figure 14-31 of the text), which create various deadlock situations.  You test class can catch the LockAbort exception, in order to print out what happened and continue.



As usual, submit a printout of each file you create or modify, with changes indicated.  NOTE:  My solution required replacing a lot of code, but the resulting amount of code did not change much.