0 Replies Latest reply on Aug 15, 2017 5:40 PM by Siva Krapa

    Keycloak: Create realm failing with deadlock

    Siva Krapa Newbie

      I am using keycloak 2.1, I am trying to create a realm using Keycloak admin rest api , getting the following error. Please help me on this.

       

      2017-08-15 13:00:41,234 WARN [org.jboss.jca.adapters.jdbc.local.LocalManagedConnectionFactory] (default task-24) IJ030006: Disabling stale connection checker for: java:jboss/datasources/KeycloakDS
      2017-08-15 13:00:41,235 WARN [org.hibernate.engine.jdbc.spi.SqlExceptionHelper] (default task-24) SQL Error: 1205, SQLState: 40001
      2017-08-15 13:00:41,236 ERROR [org.hibernate.engine.jdbc.spi.SqlExceptionHelper] (default task-24) Transaction (Process ID 152) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.
      2017-08-15 13:00:41,244 ERROR [io.undertow.request] (default task-24) UT005023: Exception handling request to /auth/admin/realms/1502827224610964322/clients/29cdf752-ebab-4815-81c5-107fde71e9cf: org.jboss.resteasy.spi.UnhandledException: javax.persistence.PersistenceException: org.hibernate.exception.LockAcquisitionException: could not execute statement
        at org.jboss.resteasy.core.ExceptionHandler.handleApplicationException(ExceptionHandler.java:76)
        at org.jboss.resteasy.core.ExceptionHandler.handleException(ExceptionHandler.java:212)
        at org.jboss.resteasy.core.SynchronousDispatcher.writeException(SynchronousDispatcher.java:168)
        at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:411)