MySQL is giving Duplicate entry for key 'REDIRECT_URIS.PRIMARY'
Issue
- MySQL 8.0.40 is giving Duplicate entry for key 'REDIRECT_URIS.PRIMARY'
2024-12-25 11:31:20,068 WARN [org.hibernate.engine.jdbc.spi.SqlExceptionHelper] (executor-thread-3) SQL Error: 1062, SQLState: 23000
2024-12-25 11:31:20,068 ERROR [org.hibernate.engine.jdbc.spi.SqlExceptionHelper] (executor-thread-3) Duplicate entry '486f905e-13db-4d56-a8e0-b60140b8088b-http://DUMMY/' for key 'REDIRECT_URIS.PRIMARY'
2024-12-25 11:31:20,071 WARN [com.arjuna.ats.arjuna] (executor-thread-3) ARJUNA012125: TwoPhaseCoordinator.beforeCompletion - failed for SynchronizationImple< 0:ffff7f000001:8f9d:676b9e48:125, org.hibernate.resource.transaction.backend.jta.internal.synchronization.RegisteredSynchronization@5c794e55 >: org.hibernate.exception.ConstraintViolationException: could not execute statement [Duplicate entry '486f905e-13db-4d56-a8e0-b60140b8088b-http://DUMMY/' for key 'REDIRECT_URIS.PRIMARY'] [insert into REDIRECT_URIS (CLIENT_ID,VALUE) values (?,?)]
at org.hibernate.exception.internal.SQLExceptionTypeDelegate.convert(SQLExceptionTypeDelegate.java:62)
at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:58)
at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:108)
Environment
- Red Hat build of Keycloak (RHBK)
- MySQL 8.0.40
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.