public interface PendingLockManager
| Modifier and Type | Method and Description |
|---|---|
long |
awaitPendingTransactionsForAllKeys(TxInvocationContext<?> ctx,
Collection<Object> keys,
long time,
TimeUnit unit)
It waits for any transaction with older topology id to complete that may have the lock for any key in
keys
acquired. |
long |
awaitPendingTransactionsForKey(TxInvocationContext<?> ctx,
Object key,
long time,
TimeUnit unit)
It waits for any transaction with older topology id to complete that may have the lock for
key acquired. |
PendingLockPromise |
checkPendingTransactionsForKey(TxInvocationContext<?> ctx,
Object key,
long time,
TimeUnit unit)
Same as
awaitPendingTransactionsForKey(TxInvocationContext, Object, long, TimeUnit) but non-blocking. |
PendingLockPromise |
checkPendingTransactionsForKeys(TxInvocationContext<?> ctx,
Collection<Object> keys,
long time,
TimeUnit unit)
Same as
awaitPendingTransactionsForAllKeys(TxInvocationContext, Collection, long, TimeUnit) but
non-blocking. |
PendingLockPromise checkPendingTransactionsForKey(TxInvocationContext<?> ctx, Object key, long time, TimeUnit unit)
awaitPendingTransactionsForKey(TxInvocationContext, Object, long, TimeUnit) but non-blocking.
Multiple invocations with the same transaction returns the same PendingLockPromise. For cleanup purposes,
awaitPendingTransactionsForKey(TxInvocationContext, Object, long, TimeUnit) must be invoked
afterwards.
ctx - the TxInvocationContext.key - the key to check.time - timeout.unit - TimeUnit of time.PendingLockPromise.PendingLockPromise checkPendingTransactionsForKeys(TxInvocationContext<?> ctx, Collection<Object> keys, long time, TimeUnit unit)
awaitPendingTransactionsForAllKeys(TxInvocationContext, Collection, long, TimeUnit) but
non-blocking.
Multiple invocations with the same transaction returns the same PendingLockPromise. For cleanup purposes,
awaitPendingTransactionsForAllKeys(TxInvocationContext, Collection, long, TimeUnit) must be invoked
afterwards.
ctx - the TxInvocationContext.keys - the keys to check.time - timeout.unit - TimeUnit of time.PendingLockPromise.long awaitPendingTransactionsForKey(TxInvocationContext<?> ctx, Object key, long time, TimeUnit unit) throws InterruptedException
key acquired.ctx - the TxInvocationContext.key - the key to check.time - timeout.unit - TimeUnit of time.InterruptedException - if the thread is interrupted while waiting.long awaitPendingTransactionsForAllKeys(TxInvocationContext<?> ctx, Collection<Object> keys, long time, TimeUnit unit) throws InterruptedException
keys
acquired.ctx - the TxInvocationContext.keys - the keys to check.time - timeout.unit - TimeUnit of time.InterruptedException - if the thread is interrupted while waiting.Copyright © 2025 JBoss, a division of Red Hat. All rights reserved.