-
Debarun Banerjee authored
Problem : --------- This issue is introduced by fix Bug #17320977 [rb#3982]. We are removing the transaction from trx_sys->rw_trx_ids after doing commit and releasing lock. This makes the order of removal of transaction from rw_trx_ids unpredictable. if a row is first updated by T1 and then by T2, it is possible that T2 is removed from the list before T1. This would cause the ReadView/snapshot of a concurrent transaction to see changes made by T2 but not T1 resulting in the inconsistency (reading part of the committed transaction T1 as the updates that are further updated by T2 are visible). Solution : ---------- During commit, remove transaction from trx_sys->rw_trx_ids & trx_sys->serialisation_list before committing transaction in memory and releasing locks. This is essentially reverting back a part of the fix in rb#3982. This ensures the serialization order (in removal from trx id list) for transactions that operated on same row. Reviewed-by:
Sunny Bains <sunny.bains@oracle.com> Reviewed-by:
Annamalai Gurusami <Annamalai.Gurusami@oracle.com> RB: 9712
Debarun Banerjee authoredProblem : --------- This issue is introduced by fix Bug #17320977 [rb#3982]. We are removing the transaction from trx_sys->rw_trx_ids after doing commit and releasing lock. This makes the order of removal of transaction from rw_trx_ids unpredictable. if a row is first updated by T1 and then by T2, it is possible that T2 is removed from the list before T1. This would cause the ReadView/snapshot of a concurrent transaction to see changes made by T2 but not T1 resulting in the inconsistency (reading part of the committed transaction T1 as the updates that are further updated by T2 are visible). Solution : ---------- During commit, remove transaction from trx_sys->rw_trx_ids & trx_sys->serialisation_list before committing transaction in memory and releasing locks. This is essentially reverting back a part of the fix in rb#3982. This ensures the serialization order (in removal from trx id list) for transactions that operated on same row. Reviewed-by:
Sunny Bains <sunny.bains@oracle.com> Reviewed-by:
Annamalai Gurusami <Annamalai.Gurusami@oracle.com> RB: 9712
Loading