Consistency Conditions for STM Sandeep Hans
Agenda Database Consistency Conditions STM Consistency Conditions A different perspective Consistency with other STM properties. Conclusion
Database Consistency Conditions Recoverability Avoiding Cascading Aborts Strictness Rigorousness
Dirty Reads T 1 writes x. T 2 reads x written by T 1. T 2 commits, T 1 aborts. T1T1 w 1 (x)a r 2 (x)c2c2 T2T2
Recoverability T 1 writes x. T 2 reads x written by T 1. T 1 should commit before T 2 commits. T1T1 w 1 (x)c1c1 r 2 (x)c2c2 T2T2
Problem with Recoverability Cascading aborts T1T1 w 1 (x) r 2 (x) T2T2 c1c1 c2c2 a1a1 a2a2
Avoiding Cascading Aborts T 1 should commit before T 2 commits reads x. T1T1 w 1 (x)c1c1 r 2 (x)c2c2 T2T2
Undo Problem Initially, x=1. T 1 writes x=2. T 2 writes x=3 and commits. T 1 aborts. T1T1 w 1 (x=2)a1a1 w 2 (x=3)c2c2 T2T2
Strictness No data item is read or overwritten unless the transaction that wrote it has ended. T1T1 w 1 (x)c 1 /a 1 r 2 (x) T2T2 w 3 (x) T3T3
Rigorousness No data item is read or overwritten unless the transaction that read/wrote it has ended. T1T1 w 1 (x)c 1 /a 1 r 2 (x) T2T2 w 3 (x) T3T3 c 2 /a 2
Landscape RG ST ACA RC [Transactional Information Systems. Gerhard Weikum, Gottfried Vossen.]
STM Conditions Opacity Guerraoui and Kapalka [ PPoPP’08] Sequential specification of shared objects. Virtual World Consistency Imbs and Raynal [SIROCCO’09] Causal past of a transaction. Weakest Reasonable Condition Doherty, Groves, Luchangco, Moir [REFINE’09]
Database vs. STM Rigorousness ⊆ Opacity ⊂ Strictness Rigorousness ⊆ VWC ⊂ Strictness ⊆ ⊆ Are these inclusions strict?
Another Perspective How do we view the system? Operation level. Database consistency conditions. Recoverability, ACA, Strictness, Rigorousness Transaction level. STM consistency conditions. Opacity, VWC Is there another level?
Snapshot Isolation Everyone will have a snapshot of the whole system. A snapshot must be consistent at every point of time. Different snapshots need not be consistent with each other. Updating of snapshots is allowed.
How consistency conditions affect STM properties. DAP + Invisible Reads + Wait-free + Serializability = Impossible. 1 We have seen the proof on Wednesday. How do Opacity/VWC affect such results. DAP + Wait-free + VWC = possible? DAP + Wait-free + Opacity = impossible? 1. Hagit Attiya, Eshcar Hillel, Alessia Milani. Inherent Limitations on Disjoint-Access Parallel Transactional Memory. SPAA 2009.
Conclusion Motivation for database and STM consistency conditions is same yet perspectives differ. STM consistency conditions affect other properties.
Thank You