Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-12038

lock manager should validate connections before setting autocommit mode on connection

    XMLWordPrintable

    Details

      Description

      Once the application is disconnected from the database in cluster mode, after the reconnection, removing a lock is throwing a storage exception.

      Caused by: org.nuxeo.ecm.core.storage.StorageException: org.postgresql.util.PSQLException: Connection has been closed automatically because a new connection was opened for the same PooledConnection or the PooledConnection has been closed.
      	at org.nuxeo.ecm.core.storage.sql.LockManager.callInTransaction(LockManager.java:334)
      	at org.nuxeo.ecm.core.storage.sql.LockManager.removeLock(LockManager.java:260)
      	at org.nuxeo.ecm.core.storage.sql.SessionImpl.removeLock(SessionImpl.java:1140)
      	at org.nuxeo.ecm.core.storage.sql.PersistenceContext.removeNode(PersistenceContext.java:829)
      	at org.nuxeo.ecm.core.storage.sql.SessionImpl.removeNode(SessionImpl.java:961)
      	at org.nuxeo.ecm.core.storage.sql.ra.ConnectionImpl.removeNode(ConnectionImpl.java:241)
      	at org.nuxeo.ecm.core.storage.sql.coremodel.SQLSession.remove(SQLSession.java:817)
      	... 123 more
      Caused by: org.postgresql.util.PSQLException: Connection has been closed automatically because a new connection was opened for the same PooledConnection or the PooledConnection has been closed.
      	at org.postgresql.ds.jdbc23.AbstractJdbc23PooledConnection$ConnectionHandler.invoke(AbstractJdbc23PooledConnection.java:297)
      	at $Proxy44.setAutoCommit(Unknown Source)
      	at sun.reflect.GeneratedMethodAccessor70.invoke(Unknown Source)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      	at java.lang.reflect.Method.invoke(Method.java:597)
      	at org.postgresql.xa.PGXAConnection$ConnectionHandler.invoke(PGXAConnection.java:156)
      	at $Proxy44.setAutoCommit(Unknown Source)
      	at org.nuxeo.ecm.core.storage.sql.LockManager.callInTransaction(LockManager.java:332)
      

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: