PicketLink IDM throwing error org.hibernate.TransactionException: Transaction not successfully started

Solution In Progress - Updated -

Issue

When there is a DB issue like java.sql.SQLRecoverableException: No more data to read from socket and login fails in IDM, the same thread will keep throwing org.hibernate.HibernateException: flush is not valid without active transaction so login will keep failing even after the DB is recovered.

17:10:00,007 ERROR [org.exoplatform.services.organization.idm.PicketLinkIDMOrganizationServiceImpl] (http-/127.0.0.1:8080-1) flush is not valid without active transaction: org.hibernate.HibernateException: flush is not valid without active transaction
    at org.hibernate.context.internal.ThreadLocalSessionContext$TransactionProtectionWrapper.invoke(ThreadLocalSessionContext.java:348)
    at com.sun.proxy.$Proxy122.flush(Unknown Source)
    at org.picketlink.idm.impl.store.hibernate.HibernateIdentityStoreSessionImpl.save(HibernateIdentityStoreSessionImpl.java:79) [picketlink-idm-hibernate-1.4.6.Final-redhat-1.jar:1.4.6.Final-redhat-1]
    at org.picketlink.idm.impl.repository.RepositoryIdentityStoreSessionImpl.save(RepositoryIdentityStoreSessionImpl.java:75) [picketlink-idm-core-1.4.6.Final-redhat-1.jar:1.4.6.Final-redhat-1]
    at org.picketlink.idm.impl.api.session.IdentitySessionImpl.save(IdentitySessionImpl.java:213) [picketlink-idm-core-1.4.6.Final-redhat-1.jar:1.4.6.Final-redhat-1]
    at org.exoplatform.services.organization.idm.PicketLinkIDMOrganizationServiceImpl.flush(PicketLinkIDMOrganizationServiceImpl.java:173) [exo.portal.component.identity-3.8.16.Final-redhat-1.jar:3.8.16.Final-redhat-1]
    at org.exoplatform.services.organization.idm.UserDAOImpl.getPopulatedUser(UserDAOImpl.java:592) [exo.portal.component.identity-3.8.16.Final-redhat-1.jar:3.8.16.Final-redhat-1]
    at org.exoplatform.services.organization.idm.UserDAOImpl.findUserByName(UserDAOImpl.java:242) [exo.portal.component.identity-3.8.16.Final-redhat-1.jar:3.8.16.Final-redhat-1]
    at org.exoplatform.services.organization.idm.UserDAOImpl.authenticate(UserDAOImpl.java:276) [exo.portal.component.identity-3.8.16.Final-redhat-1.jar:3.8.16.Final-redhat-1]
    at org.exoplatform.services.organization.auth.OrganizationAuthenticatorImpl.validateUser(OrganizationAuthenticatorImpl.java:152) [exo.core.component.organization.api-2.5.11-GA-redhat-1.jar:2.5.11-GA-redhat-1]
    at org.exoplatform.services.security.jaas.DefaultLoginModule.login(DefaultLoginModule.java:119) [exo.core.component.security.core-2.5.11-GA-redhat-1.jar:2.5.11-GA-redhat-1]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.7.0_67]
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) [rt.jar:1.7.0_67]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.7.0_67]
    at java.lang.reflect.Method.invoke(Method.java:606) [rt.jar:1.7.0_67]
    at javax.security.auth.login.LoginContext.invoke(LoginContext.java:762) [rt.jar:1.7.0_67]

Environment

  • JBoss Portal Platform (JPP)
    • 6.2

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