Class CycleDetectingLockFactory.PotentialDeadlockException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- java.lang.IllegalStateException
-
- com.google.common.util.concurrent.CycleDetectingLockFactory.ExampleStackTrace
-
- com.google.common.util.concurrent.CycleDetectingLockFactory.PotentialDeadlockException
-
- All Implemented Interfaces:
java.io.Serializable
- Enclosing class:
- CycleDetectingLockFactory
public static final class CycleDetectingLockFactory.PotentialDeadlockException extends CycleDetectingLockFactory.ExampleStackTrace
Represents a detected cycle in lock acquisition ordering. The exception includes a causal chain ofExampleStackTrace
instances to illustrate the cycle, e.g.com....PotentialDeadlockException: Potential Deadlock from LockC -> ReadWriteA at ... at ... Caused by: com...ExampleStackTrace: LockB -> LockC at ... at ... Caused by: com...ExampleStackTrace: ReadWriteA -> LockB at ... at ...
Instances are logged for the
Policies.WARN
, and thrown forPolicies.THROW
.- Since:
- 13.0
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description private CycleDetectingLockFactory.ExampleStackTrace
conflictingStackTrace
-
Fields inherited from class com.google.common.util.concurrent.CycleDetectingLockFactory.ExampleStackTrace
EMPTY_STACK_TRACE, EXCLUDED_CLASS_NAMES
-
-
Constructor Summary
Constructors Modifier Constructor Description private
PotentialDeadlockException(CycleDetectingLockFactory.LockGraphNode node1, CycleDetectingLockFactory.LockGraphNode node2, CycleDetectingLockFactory.ExampleStackTrace conflictingStackTrace)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CycleDetectingLockFactory.ExampleStackTrace
getConflictingStackTrace()
java.lang.String
getMessage()
Appends the chain of messages from theconflictingStackTrace
to the originalmessage
.
-
-
-
Field Detail
-
conflictingStackTrace
private final CycleDetectingLockFactory.ExampleStackTrace conflictingStackTrace
-
-
Constructor Detail
-
PotentialDeadlockException
private PotentialDeadlockException(CycleDetectingLockFactory.LockGraphNode node1, CycleDetectingLockFactory.LockGraphNode node2, CycleDetectingLockFactory.ExampleStackTrace conflictingStackTrace)
-
-
Method Detail
-
getConflictingStackTrace
public CycleDetectingLockFactory.ExampleStackTrace getConflictingStackTrace()
-
getMessage
public java.lang.String getMessage()
Appends the chain of messages from theconflictingStackTrace
to the originalmessage
.- Overrides:
getMessage
in classjava.lang.Throwable
-
-