hyrise-v1 icon indicating copy to clipboard operation
hyrise-v1 copied to clipboard

Make Commit Parallel

Open grundprinzip opened this issue 11 years ago • 2 comments

Currently only one TX can be committed at a time, this should be improved :)

grundprinzip avatar Jul 19 '13 09:07 grundprinzip

How would you propose to do this? The only problem I see is the synchronization of deletes. So we have to make sure that not two transactions delete the same row. We could use the TID as a lock of a row, so a transaction that wants to delete a row writes its TID in that row instead. The write uses an atomic TestAndSet so that it fails if some other TID is already written in the row...

This would result in the following states of a row:

v.TID v.BeginCID v.EndCID LastCID Status
-- Inf Inf 12 Init
5 Inf Inf 12 Insert uncommitted
5 13 Inf 12 Insert commit in prog.
5 13 Inf 13 Insert committed
-- 13 Inf 13 Insert committed (cleaned up)
6 13 Inf 13 delete uncommited
6 13 14 13 delete commit in prog.
6 13 14 14 delete committed

schwald avatar Aug 13 '13 12:08 schwald

If the TID servers as a row-level lock, how do we handle deadlocks?

schwald avatar Aug 15 '13 08:08 schwald