Package liquibase.lockservice
Class OfflineLockService
- java.lang.Object
-
- liquibase.lockservice.OfflineLockService
-
- All Implemented Interfaces:
LockService
,PrioritizedService
public class OfflineLockService extends Object implements LockService
-
-
Field Summary
-
Fields inherited from interface liquibase.servicelocator.PrioritizedService
COMPARATOR, PRIORITY_DATABASE, PRIORITY_DEFAULT
-
-
Constructor Summary
Constructors Constructor Description OfflineLockService()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
acquireLock()
void
destroy()
void
forceReleaseLock()
Releases whatever locks are on the database change log tableint
getPriority()
boolean
hasChangeLogLock()
void
init()
DatabaseChangeLogLock[]
listLocks()
void
releaseLock()
void
reset()
Clears information the lock handler knows about the tables.void
setChangeLogLockRecheckTime(long changeLogLockRecheckTime)
void
setChangeLogLockWaitTime(long changeLogLockWaitTime)
void
setDatabase(Database database)
boolean
supports(Database database)
void
waitForLock()
-
-
-
Method Detail
-
getPriority
public int getPriority()
- Specified by:
getPriority
in interfacePrioritizedService
-
supports
public boolean supports(Database database)
- Specified by:
supports
in interfaceLockService
-
init
public void init() throws DatabaseException
- Specified by:
init
in interfaceLockService
- Throws:
DatabaseException
-
setDatabase
public void setDatabase(Database database)
- Specified by:
setDatabase
in interfaceLockService
-
setChangeLogLockWaitTime
public void setChangeLogLockWaitTime(long changeLogLockWaitTime)
- Specified by:
setChangeLogLockWaitTime
in interfaceLockService
-
setChangeLogLockRecheckTime
public void setChangeLogLockRecheckTime(long changeLogLockRecheckTime)
- Specified by:
setChangeLogLockRecheckTime
in interfaceLockService
-
hasChangeLogLock
public boolean hasChangeLogLock()
- Specified by:
hasChangeLogLock
in interfaceLockService
-
waitForLock
public void waitForLock() throws LockException
- Specified by:
waitForLock
in interfaceLockService
- Throws:
LockException
-
acquireLock
public boolean acquireLock() throws LockException
- Specified by:
acquireLock
in interfaceLockService
- Throws:
LockException
-
releaseLock
public void releaseLock() throws LockException
- Specified by:
releaseLock
in interfaceLockService
- Throws:
LockException
-
listLocks
public DatabaseChangeLogLock[] listLocks() throws LockException
- Specified by:
listLocks
in interfaceLockService
- Throws:
LockException
-
forceReleaseLock
public void forceReleaseLock() throws LockException, DatabaseException
Description copied from interface:LockService
Releases whatever locks are on the database change log table- Specified by:
forceReleaseLock
in interfaceLockService
- Throws:
LockException
DatabaseException
-
reset
public void reset()
Description copied from interface:LockService
Clears information the lock handler knows about the tables. Should only be called by Liquibase internal calls- Specified by:
reset
in interfaceLockService
-
destroy
public void destroy() throws DatabaseException
- Specified by:
destroy
in interfaceLockService
- Throws:
DatabaseException
-
-