liquibase.lockservice
public class StandardLockService extends java.lang.Object implements LockService
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
LOCK_WAIT_TIME_SYSTEM_PROPERTY |
PRIORITY_DATABASE, PRIORITY_DEFAULT
Constructor and Description |
---|
StandardLockService() |
Modifier and Type | Method and Description |
---|---|
boolean |
acquireLock() |
void |
destroy() |
void |
forceReleaseLock()
Releases whatever locks are on the database change log table
|
int |
getPriority() |
boolean |
hasChangeLogLock() |
boolean |
hasDatabaseChangeLogLockTable() |
void |
init() |
boolean |
isDatabaseChangeLogLockTableInitialized(boolean tableJustCreated) |
DatabaseChangeLogLock[] |
listLocks() |
void |
releaseLock() |
void |
reset()
Clears information the lock handler knows about the tables.
|
void |
setChangeLogLockRecheckTime(long changeLogLocRecheckTime) |
void |
setChangeLogLockWaitTime(long changeLogLockWaitTime) |
void |
setDatabase(Database database) |
boolean |
supports(Database database) |
void |
waitForLock() |
public static final java.lang.String LOCK_WAIT_TIME_SYSTEM_PROPERTY
public int getPriority()
getPriority
in interface PrioritizedService
public boolean supports(Database database)
supports
in interface LockService
public void setDatabase(Database database)
setDatabase
in interface LockService
public void setChangeLogLockWaitTime(long changeLogLockWaitTime)
setChangeLogLockWaitTime
in interface LockService
public void setChangeLogLockRecheckTime(long changeLogLocRecheckTime)
setChangeLogLockRecheckTime
in interface LockService
public void init() throws DatabaseException
init
in interface LockService
DatabaseException
public boolean isDatabaseChangeLogLockTableInitialized(boolean tableJustCreated) throws DatabaseException
DatabaseException
public boolean hasChangeLogLock()
hasChangeLogLock
in interface LockService
public boolean hasDatabaseChangeLogLockTable() throws DatabaseException
DatabaseException
public void waitForLock() throws LockException
waitForLock
in interface LockService
LockException
public boolean acquireLock() throws LockException
acquireLock
in interface LockService
LockException
public void releaseLock() throws LockException
releaseLock
in interface LockService
LockException
public DatabaseChangeLogLock[] listLocks() throws LockException
listLocks
in interface LockService
LockException
public void forceReleaseLock() throws LockException, DatabaseException
LockService
forceReleaseLock
in interface LockService
LockException
DatabaseException
public void reset()
LockService
reset
in interface LockService
public void destroy() throws DatabaseException
destroy
in interface LockService
DatabaseException