Uploaded image for project: 'OpenOLAT'
  1. OpenOLAT
  2. OO-2992

LDAP sync: concurrent update of user

    XMLWordPrintable

    Details

      Description

      Solution: reload before update

      2017-09-06 09:07:07,458 [mpTaskSpringExecutor-1] ERROR LDAPLoginManagerImpl  - OLAT::ERROR ^%^ N58-E695 ^%^ org.olat.ldap.manager ^%^ n/a ^%^ n/a ^%^ n/a ^%^ n/a ^%^ Error in LDAP batch sync, unknown reason
      >>>stack of 1.cause::javax.persistence.OptimisticLockException: Row was updated or deleted by another transaction (or unsaved-value mapping was incorrect) : [org.olat.user.UserImpl#45849952]
      -> at org.hibernate.internal.ExceptionConverterImpl.wrapStaleStateException(ExceptionConverterImpl.java:197)
         at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:86)
         at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:155)
         at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:162)
         at org.hibernate.internal.SessionImpl.fireMerge(SessionImpl.java:893)
         at org.hibernate.internal.SessionImpl.merge(SessionImpl.java:867)
         at org.olat.user.UserManagerImpl.updateUser(UserManagerImpl.java:353)
         at org.olat.ldap.manager.LDAPLoginManagerImpl.syncUser(LDAPLoginManagerImpl.java:483)
         at org.olat.ldap.manager.LDAPLoginManagerImpl.doBatchSyncNewAndModifiedUsers(LDAPLoginManagerImpl.java:1188)
         at org.olat.ldap.manager.LDAPLoginManagerImpl.doBatchSync(LDAPLoginManagerImpl.java:924)
         at org.olat.ldap.manager.LDAPLoginManagerImpl$1.run(LDAPLoginManagerImpl.java:195)
      >>>stack of 2.cause::org.hibernate.StaleObjectStateException: Row was updated or deleted by another transaction (or unsaved-value mapping was incorrect) : [org.olat.user.UserImpl#45849952]
      -> at org.hibernate.event.internal.DefaultMergeEventListener.entityIsDetached(DefaultMergeEventListener.java:322)
         at org.hibernate.event.internal.DefaultMergeEventListener.onMerge(DefaultMergeEventListener.java:170)
         at org.hibernate.event.internal.DefaultMergeEventListener.onMerge(DefaultMergeEventListener.java:69)
         at org.hibernate.internal.SessionImpl.fireMerge(SessionImpl.java:881)
         at org.hibernate.internal.SessionImpl.merge(SessionImpl.java:867)
         at org.olat.user.UserManagerImpl.updateUser(UserManagerImpl.java:353)
         at org.olat.ldap.manager.LDAPLoginManagerImpl.syncUser(LDAPLoginManagerImpl.java:483)
         at org.olat.ldap.manager.LDAPLoginManagerImpl.doBatchSyncNewAndModifiedUsers(LDAPLoginManagerImpl.java:1188)
         at org.olat.ldap.manager.LDAPLoginManagerImpl.doBatchSync(LDAPLoginManagerImpl.java:924)
         at org.olat.ldap.manager.LDAPLoginManagerImpl$1.run(LDAPLoginManagerImpl.java:195)
         at org.olat.core.commons.services.taskexecutor.model.DBSecureRunnable.run(DBSecureRunnable.java:42)
      

        Attachments

          Activity

            People

            Assignee:
            srosse Stéphane Rossé
            Reporter:
            srosse Stéphane Rossé
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 1 hour, 5 minutes
                1h 5m