You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
OptimisticTransaction::CommitWithParallelValidate() actually prevent race between TransactionUtil::CheckKeysForConflicts() and DBImpl::Write(), as implied by its example code
Actual behavior
OptimisticTransaction::CommitWithParallelValidate() cannot prevect race between TransactionUtil::CheckKeysForConflicts() and DBImpl::Write()
The moment thread T1 has just done executing L123, another thread T2 write something into db, then T1 executes L129, the transaction will falsely commit, contrary to what is implied by the occ example code
The text was updated successfully, but these errors were encountered:
andoryu-
changed the title
race in OptimisticTransaction::CommitWithParallelValidate
race condition in OptimisticTransaction::CommitWithParallelValidate
Sep 16, 2022
Expected behavior
OptimisticTransaction::CommitWithParallelValidate() actually prevent race between TransactionUtil::CheckKeysForConflicts() and DBImpl::Write(), as implied by its example code
Actual behavior
OptimisticTransaction::CommitWithParallelValidate() cannot prevect race between TransactionUtil::CheckKeysForConflicts() and DBImpl::Write()
Steps to reproduce the behavior
Read the source code, sepcifically between calling TransactionUtil::CheckKeysForConflicts and calling DBImpl::Write()
The moment thread T1 has just done executing L123, another thread T2 write something into db, then T1 executes L129, the transaction will falsely commit, contrary to what is implied by the occ example code
The text was updated successfully, but these errors were encountered: