Violation of PRIMARY KEY constraint 'CONSTRAINT_OFFL_CL_SES_PK3' on RH-SSO 7.4+

Solution Verified - Updated -

Issue

When the apps are refreshing the access token using the offline tokens, noticed the CONSTRAINT_OFFL_CL_SES_PK3 violation on the OFFLINE_CLIENT_SESSION table as follows:

[org.hibernate.engine.jdbc.spi.SqlExceptionHelper] (default task-173) Violation of PRIMARY KEY constraint 'CONSTRAINT_OFFL_CL_SES_PK3'. Cannot insert duplicate key in object 'dbo.OFFLINE_CLIENT_SESSION'. The duplicate key value is (ae21f5d4-7af2-4560-a181-166b022f29c4, c7ae7513-ff3a-431e-b357-a7bf9558a767, local, local, 1).

The issue started after upgrading RHSSO from 7.3.8 to 7.5.x

Environment

  • Red Hat Single Sing-on (RH-SSO)
    • 7.4.x

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content