org.keycloak.connections.jpa.updater.liquibase.lock

## Class CustomLockService

- java.lang.Object
- - liquibase.lockservice.StandardLockService
  - - org.keycloak.connections.jpa.updater.liquibase.lock.CustomLockService

- All Implemented Interfaces:
    liquibase.lockservice.LockService, liquibase.servicelocator.PrioritizedService

      public class CustomLockService
      extends liquibase.lockservice.StandardLockService

  Liquibase lock service, which has some bugfixes and assumes timeouts to be configured in milliseconds
  Author:
    Marek Posolda

- - ### Field Summary

    - ### Fields inherited from class liquibase.lockservice.StandardLockService

      `database, hasChangeLogLock`

    - ### Fields inherited from interface liquibase.servicelocator.PrioritizedService

      `COMPARATOR, PRIORITY_DATABASE, PRIORITY_DEFAULT`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `CustomLockService()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `acquireLock()`
    `void` | `init()`
    `boolean` | `isDatabaseChangeLogLockTableInitialized(boolean tableJustCreated)`
    `void` | `releaseLock()`
    `void` | `waitForLock()`
    `void` | `waitForLock(DBLockProvider.Namespace lock)`

    - ### Methods inherited from class liquibase.lockservice.StandardLockService

      `destroy, forceReleaseLock, getChangeLogLockRecheckTime, getChangeLogLockWaitTime, getPriority, hasChangeLogLock, hasDatabaseChangeLogLockTable, listLocks, reset, setChangeLogLockRecheckTime, setChangeLogLockWaitTime, setDatabase, supports`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### CustomLockService

          public CustomLockService()

  - ### Method Detail

    - #### init

          public void init()
                    throws liquibase.exception.DatabaseException

      Specified by:
        `init` in interface `liquibase.lockservice.LockService`
      Overrides:
        `init` in class `liquibase.lockservice.StandardLockService`
      Throws:
        `liquibase.exception.DatabaseException`

    - #### isDatabaseChangeLogLockTableInitialized

          public boolean isDatabaseChangeLogLockTableInitialized(boolean tableJustCreated)
                                                          throws liquibase.exception.DatabaseException

      Overrides:
        `isDatabaseChangeLogLockTableInitialized` in class `liquibase.lockservice.StandardLockService`
      Throws:
        `liquibase.exception.DatabaseException`

    - #### waitForLock

          public void waitForLock()

      Specified by:
        `waitForLock` in interface `liquibase.lockservice.LockService`
      Overrides:
        `waitForLock` in class `liquibase.lockservice.StandardLockService`

    - #### waitForLock

          public void waitForLock(DBLockProvider.Namespace lock)

    - #### acquireLock

          public boolean acquireLock()

      Specified by:
        `acquireLock` in interface `liquibase.lockservice.LockService`
      Overrides:
        `acquireLock` in class `liquibase.lockservice.StandardLockService`

    - #### releaseLock

          public void releaseLock()

      Specified by:
        `releaseLock` in interface `liquibase.lockservice.LockService`
      Overrides:
        `releaseLock` in class `liquibase.lockservice.StandardLockService`

Copyright © 2021 JBoss by Red Hat. All rights reserved.