public interface DeadlockChecker
| Modifier and Type | Method and Description |
|---|---|
boolean |
deadlockDetected(Object pendingOwner,
Object currentOwner)
It checks for deadlock.
|
boolean deadlockDetected(Object pendingOwner, Object currentOwner)
It accepts two arguments: the pendingOwner is a lock owner that tries to acquire the lock and the currentOwner is the current lock owner. If a deadlock is detected and the pendingOwner must rollback, it
must return true. If no deadlock is found or the currentOwner must rollback, it must return false.
This method may be invoked multiples times and in multiple threads. Thread safe is advised.
pendingOwner - a lock owner that tries to acquire the lock.currentOwner - the current lock owner.true if a deadlock is detected and the pendingOwner must rollback.Copyright © 2024 JBoss, a division of Red Hat. All rights reserved.