public abstract class AbstractLocker extends Object implements Locker
| Modifier and Type | Field and Description |
|---|---|
protected static String |
LOCK_SPLIT
The constant LOCK_SPLIT.
|
protected static org.slf4j.Logger |
LOGGER
The constant LOGGER.
|
| Constructor and Description |
|---|
AbstractLocker() |
| Modifier and Type | Method and Description |
|---|---|
void |
cleanAllLocks()
Clean all locks.
|
protected List<LockDO> |
convertToLockDO(List<RowLock> locks)
Convert to lock do list.
|
protected LockDO |
convertToLockDO(RowLock rowLock) |
protected String |
getRowKey(String resourceId,
String tableName,
String pk)
Get row key string.
|
boolean |
releaseLock(List<RowLock> rowLock)
Release lock boolean.
|
boolean |
releaseLock(String xid)
Release lock boolean.
|
boolean |
releaseLock(String xid,
Long branchId)
Release lock boolean.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitacquireLock, acquireLock, isLockable, updateLockStatusprotected static final org.slf4j.Logger LOGGER
protected static final String LOCK_SPLIT
protected List<LockDO> convertToLockDO(List<RowLock> locks)
locks - the locksprotected String getRowKey(String resourceId, String tableName, String pk)
resourceId - the resource idtableName - the table namepk - the pkpublic void cleanAllLocks()
LockercleanAllLocks in interface Lockerpublic boolean releaseLock(List<RowLock> rowLock)
LockerreleaseLock in interface LockerrowLock - the row lockpublic boolean releaseLock(String xid, Long branchId)
LockerreleaseLock in interface Lockerxid - the xidbranchId - the branch idpublic boolean releaseLock(String xid)
LockerreleaseLock in interface Lockerxid - the xidCopyright © 2023 Seata. All rights reserved.