Make : make
Start deadlock detector : python3 deadlock.py 9999
Start 5 servers : python3 run.py
Run client : ./client num(0-9)
./client 0
./client 1
Atomic, Consistency, Isolation with deadlock detection
At start up, the client should automatically connect to all the necessary servers and start accepting commands typed in by the user. The user will execute the following commands:
BEGIN: Open a new transaction, and reply with “OK”.
SET server.key value:
Set the value of an object with the named key stored on the named server. E.g.:
SET A.x 1
SET B.y 2
GET server.key: Get the value of the object named by the key on the named server.
Reply with: server.key = value on a separate line. E.g.:
GET A.x
A.x = 1
If a query is made to an object that has not previously been SET, you should return NOT FOUND and abort the transaction.
Commit the transaction, making its results visible to other transactions.
The client should reply either with COMMIT OK or ABORTED, in the case that the transaction had to be aborted during the commit process.
Abort the transaction. All updates made during the transaction must be rolled back. The client should reply with ABORTED to confirm that the transaction was aborted.