Skip to content

Commit

Permalink
comments
Browse files Browse the repository at this point in the history
  • Loading branch information
arjunsk committed Jun 13, 2024
1 parent 4e8003c commit 22d7aea
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions pkg/txn/c_scheduler.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ func (o *Oracle) hasConflictFor(txn *Txn) bool {

for _, readyToCommitTxn := range o.readyToCommitTxns {
if readyToCommitTxn.commitTs <= currTxnBeginTs {
// skip txns which doesn't have temporal overlap
continue
}

Expand All @@ -111,6 +112,7 @@ func (o *Oracle) gcOldReadyToCommitTxns() {

for _, readyToCommitTxn := range o.readyToCommitTxns {
if readyToCommitTxn.commitTs <= lastActiveReadTs {
// skip adding txns who are older than the last active readTs
continue
}
updatedReadyToCommitTxns = append(updatedReadyToCommitTxns, readyToCommitTxn)
Expand Down

0 comments on commit 22d7aea

Please sign in to comment.