ascherbakoff commented on code in PR #7799:
URL: https://github.com/apache/ignite-3/pull/7799#discussion_r3071213889
##########
modules/transactions/src/main/java/org/apache/ignite/internal/tx/impl/HeapLockManager.java:
##########
@@ -630,7 +625,7 @@ public CompletableFuture<Lock> acquire(UUID txId, LockMode
lockMode) {
// Prevent deadlocks by allowing only younger
transactions to wait.
for (Lock lock : ixlockOwners.values()) {
- if
(deadlockPreventionPolicy.txIdComparator().compare(txId, lock.txId()) < 0) {
+ if (TransactionIds.compare(txId, lock.txId())
< 0) {
Review Comment:
This implementation is correct.
A reversed wait-die policy is currently always used for coarse locks to
avoid deadlocks.
This may be changed in the future.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]