Class LockCleaner<T extends Lock>
java.lang.Object
org.eclipse.rdf4j.common.concurrent.locks.diagnostics.LockCleaner<T>
- All Implemented Interfaces:
LockMonitoring<T>
@InternalUseOnly
public class LockCleaner<T extends Lock>
extends Object
implements LockMonitoring<T>
Automatically log and release locks that are no longer referenced and will be garbage collected.
- Author:
- HÃ¥vard M. Ottestad
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.eclipse.rdf4j.common.concurrent.locks.diagnostics.LockMonitoring
LockMonitoring.Wrapper<T extends Lock>
-
Field Summary
Fields inherited from interface org.eclipse.rdf4j.common.concurrent.locks.diagnostics.LockMonitoring
INITIAL_WAIT_TO_COLLECT
-
Constructor Summary
ConstructorDescriptionLockCleaner
(boolean stacktrace, String alias, org.slf4j.Logger logger, Lock.ExtendedSupplier<T> supplier) -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.eclipse.rdf4j.common.concurrent.locks.diagnostics.LockMonitoring
getLock, requiresManualCleanup, runCleanup
-
Constructor Details
-
LockCleaner
public LockCleaner(boolean stacktrace, String alias, org.slf4j.Logger logger, Lock.ExtendedSupplier<T> supplier)
-
-
Method Details
-
getLock
- Specified by:
getLock
in interfaceLockMonitoring<T extends Lock>
- Throws:
InterruptedException
-
tryLock
- Specified by:
tryLock
in interfaceLockMonitoring<T extends Lock>
-
unsafeInnerLock
- Specified by:
unsafeInnerLock
in interfaceLockMonitoring<T extends Lock>
-
register
-
unregister
- Specified by:
unregister
in interfaceLockMonitoring<T extends Lock>
-