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

Fix DirectoryCache concurrency

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 9.3-SNAPSHOT
    • Fix Version/s: 9.3
    • Component/s: Directory

      Description

      Under concurrency the following exception is raised, this corrupts the workmanager metrics and prevents to run benchmarks.

      2017-11-06 05:28:17,112 ERROR [Nuxeo-Work-default-3] [org.nuxeo.ecm.core.work.WorkManagerImpl] Uncaught error on thread: Nuxeo-Work-default-3, current work might be lost, WorkManager metrics might be corrupted.
      java.util.ConcurrentModificationException
              at java.util.HashMap$HashIterator.nextNode(HashMap.java:1429)
              at java.util.HashMap$ValueIterator.next(HashMap.java:1458)
              at java.util.Collections$UnmodifiableCollection$1.next(Collections.java:1042)
              at org.nuxeo.ecm.core.api.model.impl.ComplexProperty.internalGetValue(ComplexProperty.java:161)
              at org.nuxeo.ecm.core.api.model.impl.AbstractProperty.getValue(AbstractProperty.java:453)
              at org.nuxeo.ecm.core.api.impl.DataModelImpl.getMap(DataModelImpl.java:107)
              at org.nuxeo.ecm.core.api.impl.DocumentModelImpl.clone(DocumentModelImpl.java:1399)
              at org.nuxeo.ecm.directory.DirectoryCache.getEntry(DirectoryCache.java:138)
              at org.nuxeo.ecm.directory.BaseSession.getEntry(BaseSession.java:331)
              at org.nuxeo.ecm.directory.BaseSession.getEntry(BaseSession.java:319)
              at org.nuxeo.ecm.platform.usermanager.UserManagerImpl.getGroupModel(UserManagerImpl.java:1112)
              at org.nuxeo.ecm.platform.usermanager.UserManagerImpl.getGroup(UserManagerImpl.java:608)
              at org.nuxeo.ecm.platform.computedgroups.UserManagerWithComputedGroups.getGroup(UserManagerWithComputedGroups.java:123)
              at org.nuxeo.ecm.platform.usermanager.UserManagerImpl.getGroup(UserManagerImpl.java:604)
              at org.nuxeo.ecm.platform.computedgroups.UserManagerWithComputedGroups.getGroup(UserManagerWithComputedGroups.java:111)
              at org.nuxeo.ecm.platform.usermanager.NuxeoPrincipalImpl.updateAllGroups(NuxeoPrincipalImpl.java:332)
              at org.nuxeo.ecm.platform.usermanager.NuxeoPrincipalImpl.setVirtualGroups(NuxeoPrincipalImpl.java:388)
              at org.nuxeo.ecm.platform.usermanager.UserManagerImpl.makePrincipal(UserManagerImpl.java:556)
              at org.nuxeo.ecm.platform.usermanager.UserManagerImpl.makePrincipal(UserManagerImpl.java:527)
              at org.nuxeo.ecm.platform.computedgroups.UserManagerWithComputedGroups.makePrincipal(UserManagerWithComputedGroups.java:73)
              at org.nuxeo.ecm.platform.usermanager.UserManagerImpl.makePrincipal(UserManagerImpl.java:523)
              at org.nuxeo.ecm.platform.usermanager.UserManagerImpl.getPrincipal(UserManagerImpl.java:1166)
              at org.nuxeo.ecm.platform.usermanager.UserManagerImpl.getPrincipalUsingCache(UserManagerImpl.java:582)
              at org.nuxeo.ecm.platform.usermanager.UserManagerImpl.getPrincipal(UserManagerImpl.java:574)
              at org.nuxeo.ecm.platform.usermanager.NuxeoPrincipalImpl$TransferableClone$DataTransferObject.lambda$readResolve$0(NuxeoPrincipalImpl.java:486)
              at org.nuxeo.runtime.api.Framework.doPrivileged(Framework.java:278)
              at org.nuxeo.ecm.platform.usermanager.NuxeoPrincipalImpl$TransferableClone$DataTransferObject.readResolve(NuxeoPrincipalImpl.java:486)
              at sun.reflect.GeneratedMethodAccessor263.invoke(Unknown Source)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
              at java.lang.reflect.Method.invoke(Method.java:497)
              at java.io.ObjectStreamClass.invokeReadResolve(ObjectStreamClass.java:1148)
              at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1810)
              at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
              at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
              at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
              at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
              at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
              at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
              at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
              at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
              at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
              at java.io.ObjectInputStream.readObject(ObjectInputStream.java:371)
              at java.util.ArrayList.readObject(ArrayList.java:791)
              at sun.reflect.GeneratedMethodAccessor238.invoke(Unknown Source)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
              at java.lang.reflect.Method.invoke(Method.java:497)
              at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1058)
              at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1900)
              at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
              at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
              at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
              at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
              at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
              at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
              at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
              at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
              at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
              at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
              at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
              at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
              at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
              at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
              at java.io.ObjectInputStream.readObject(ObjectInputStream.java:371)
              at org.nuxeo.ecm.core.redis.contribs.RedisWorkQueuing.deserializeWork(RedisWorkQueuing.java:455)
      

        Attachments

          Issue Links

            Activity

              People

              • 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 - 30 minutes
                  30m