com.orientechnologies.orient.core.exception.OConcurrentModificationException: Cannot UPDATE the record #9:293 because the version is not the latest. Probably you are updating an old record or it has been modified by another user (db=v6 your=v5)

Sonatype JIRA | Peter Lynch | 2 years ago
  1. 0

    The npm database can get in a state where expiring the not found cache on an npm repository can trigger an OConcurrentModificationException if package metadata is updated at the same time by another thread. The other thread would typically be a get or PUT request for an npm package. {{com.orientechnologies.orient.core.exception.OConcurrentModificationException: Cannot UPDATE the record #9:293 because the version is not the latest. Probably you are updating an old record or it has been modified by another user (db=v6 your=v5) }} {noformat} 2015-05-07 11:14:27,457-0400 INFO [qtp1949268043-463] admin org.sonatype.nexus.logging.rest.LogResource - ************************* * expire cache at 11:00 * ************************* 2015-05-07 11:14:40,605-0400 INFO [pxpool-1-thread-1] admin org.sonatype.nexus.tasks.ExpireCacheTask - Scheduled task (ExpireCacheTask) started :: Expiring caches for repository npm from path / and below. 2015-05-07 11:14:42,305-0400 WARN [pxpool-1-thread-1] admin org.sonatype.nexus.tasks.ExpireCacheTask - Scheduled task (ExpireCacheTask) failed :: Expiring caches for repository npm from path / and below. (started 2015-05-07T11:14:40-04:00, runtime 0:00:01.697) com.orientechnologies.orient.core.exception.OConcurrentModificationException: Cannot UPDATE the record #9:293 because the version is not the latest. Probably you are updating an old record or it has been modified by another user (db=v6 your=v5) at com.orientechnologies.orient.core.conflict.OVersionRecordConflictStrategy.checkVersions(OVersionRecordConflictStrategy.java:54) ~[na:na] at com.orientechnologies.orient.core.conflict.OVersionRecordConflictStrategy.onUpdate(OVersionRecordConflictStrategy.java:41) ~[na:na] at com.orientechnologies.orient.core.storage.impl.local.OAbstractPaginatedStorage.checkAndIncrementVersion(OAbstractPaginatedStorage.java:2009) ~[na:na] at com.orientechnologies.orient.core.storage.impl.local.OAbstractPaginatedStorage.doUpdateRecord(OAbstractPaginatedStorage.java:1643) ~[na:na] at com.orientechnologies.orient.core.storage.impl.local.OAbstractPaginatedStorage.commitEntry(OAbstractPaginatedStorage.java:2094) ~[na:na] at com.orientechnologies.orient.core.storage.impl.local.OAbstractPaginatedStorage.commit(OAbstractPaginatedStorage.java:910) ~[na:na] at com.orientechnologies.orient.core.tx.OTransactionOptimistic.doCommit(OTransactionOptimistic.java:483) ~[na:na] at com.orientechnologies.orient.core.tx.OTransactionOptimistic.commit(OTransactionOptimistic.java:147) ~[na:na] at com.orientechnologies.orient.core.db.document.ODatabaseDocumentTx.commit(ODatabaseDocumentTx.java:2370) ~[na:na] at com.orientechnologies.orient.core.db.document.ODatabaseDocumentTx.commit(ODatabaseDocumentTx.java:2340) ~[na:na] at com.bolyuba.nexus.plugin.npm.service.internal.orient.OrientMetadataStore.updatePackages(OrientMetadataStore.java:334) ~[na:na] at com.bolyuba.nexus.plugin.npm.service.internal.ProxyMetadataServiceImpl.expireMetadataCaches(ProxyMetadataServiceImpl.java:83) ~[na:na] at com.bolyuba.nexus.plugin.npm.proxy.DefaultNpmProxyRepository.doExpireProxyCaches(DefaultNpmProxyRepository.java:150) ~[na:na] at org.sonatype.nexus.proxy.repository.AbstractProxyRepository.doExpireCaches(AbstractProxyRepository.java:356) ~[nexus-core-2.11.2-06.jar:2.11.2-06] at org.sonatype.nexus.proxy.repository.AbstractRepository.expireCaches(AbstractRepository.java:430) ~[nexus-core-2.11.2-06.jar:2.11.2-06] at org.sonatype.nexus.proxy.repository.AbstractGroupRepository.doExpireCaches(AbstractGroupRepository.java:133) ~[nexus-core-2.11.2-06.jar:2.11.2-06] at org.sonatype.nexus.proxy.repository.AbstractRepository.expireCaches(AbstractRepository.java:430) ~[nexus-core-2.11.2-06.jar:2.11.2-06] at org.sonatype.nexus.proxy.repository.AbstractRepository.expireCaches(AbstractRepository.java:421) ~[nexus-core-2.11.2-06.jar:2.11.2-06] at org.sonatype.nexus.tasks.ExpireCacheTask.doRun(ExpireCacheTask.java:51) ~[nexus-core-2.11.2-06.jar:2.11.2-06] at org.sonatype.nexus.scheduling.AbstractNexusTask.call(AbstractNexusTask.java:151) ~[nexus-core-2.11.2-06.jar:2.11.2-06] at org.sonatype.scheduling.DefaultScheduledTask.call(DefaultScheduledTask.java:418) [nexus-scheduler-2.11.2-06.jar:2.11.2-06] at org.sonatype.nexus.threads.MDCAwareCallable.call(MDCAwareCallable.java:44) [nexus-core-2.11.2-06.jar:2.11.2-06] at org.apache.shiro.subject.support.SubjectCallable.doCall(SubjectCallable.java:90) [shiro-core-1.2.3.jar:1.2.3] at org.apache.shiro.subject.support.SubjectCallable.call(SubjectCallable.java:83) [shiro-core-1.2.3.jar:1.2.3] at java.util.concurrent.FutureTask.run(FutureTask.java:262) [na:1.7.0_45] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:178) [na:1.7.0_45] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:292) [na:1.7.0_45] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [na:1.7.0_45] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [na:1.7.0_45] at java.lang.Thread.run(Thread.java:744) [na:1.7.0_45] 2015-05-07 11:14:42,340-0400 WARN [pxpool-1-thread-1] admin org.sonatype.scheduling.DefaultScheduledTask - Exception in call method of scheduled task Internal com.orientechnologies.orient.core.exception.OConcurrentModificationException: Cannot UPDATE the record #9:293 because the version is not the latest. Probably you are updating an old record or it has been modified by another user (db=v6 your=v5) at com.orientechnologies.orient.core.conflict.OVersionRecordConflictStrategy.checkVersions(OVersionRecordConflictStrategy.java:54) ~[na:na] at com.orientechnologies.orient.core.conflict.OVersionRecordConflictStrategy.onUpdate(OVersionRecordConflictStrategy.java:41) ~[na:na] at com.orientechnologies.orient.core.storage.impl.local.OAbstractPaginatedStorage.checkAndIncrementVersion(OAbstractPaginatedStorage.java:2009) ~[na:na] at com.orientechnologies.orient.core.storage.impl.local.OAbstractPaginatedStorage.doUpdateRecord(OAbstractPaginatedStorage.java:1643) ~[na:na] at com.orientechnologies.orient.core.storage.impl.local.OAbstractPaginatedStorage.commitEntry(OAbstractPaginatedStorage.java:2094) ~[na:na] at com.orientechnologies.orient.core.storage.impl.local.OAbstractPaginatedStorage.commit(OAbstractPaginatedStorage.java:910) ~[na:na] at com.orientechnologies.orient.core.tx.OTransactionOptimistic.doCommit(OTransactionOptimistic.java:483) ~[na:na] at com.orientechnologies.orient.core.tx.OTransactionOptimistic.commit(OTransactionOptimistic.java:147) ~[na:na] at com.orientechnologies.orient.core.db.document.ODatabaseDocumentTx.commit(ODatabaseDocumentTx.java:2370) ~[na:na] at com.orientechnologies.orient.core.db.document.ODatabaseDocumentTx.commit(ODatabaseDocumentTx.java:2340) ~[na:na] at com.bolyuba.nexus.plugin.npm.service.internal.orient.OrientMetadataStore.updatePackages(OrientMetadataStore.java:334) ~[na:na] at com.bolyuba.nexus.plugin.npm.service.internal.ProxyMetadataServiceImpl.expireMetadataCaches(ProxyMetadataServiceImpl.java:83) ~[na:na] at com.bolyuba.nexus.plugin.npm.proxy.DefaultNpmProxyRepository.doExpireProxyCaches(DefaultNpmProxyRepository.java:150) ~[na:na] at org.sonatype.nexus.proxy.repository.AbstractProxyRepository.doExpireCaches(AbstractProxyRepository.java:356) ~[nexus-core-2.11.2-06.jar:2.11.2-06] at org.sonatype.nexus.proxy.repository.AbstractRepository.expireCaches(AbstractRepository.java:430) ~[nexus-core-2.11.2-06.jar:2.11.2-06] at org.sonatype.nexus.proxy.repository.AbstractGroupRepository.doExpireCaches(AbstractGroupRepository.java:133) ~[nexus-core-2.11.2-06.jar:2.11.2-06] at org.sonatype.nexus.proxy.repository.AbstractRepository.expireCaches(AbstractRepository.java:430) ~[nexus-core-2.11.2-06.jar:2.11.2-06] at org.sonatype.nexus.proxy.repository.AbstractRepository.expireCaches(AbstractRepository.java:421) ~[nexus-core-2.11.2-06.jar:2.11.2-06] at org.sonatype.nexus.tasks.ExpireCacheTask.doRun(ExpireCacheTask.java:51) ~[nexus-core-2.11.2-06.jar:2.11.2-06] at org.sonatype.nexus.scheduling.AbstractNexusTask.call(AbstractNexusTask.java:151) ~[nexus-core-2.11.2-06.jar:2.11.2-06] at org.sonatype.scheduling.DefaultScheduledTask.call(DefaultScheduledTask.java:418) ~[nexus-scheduler-2.11.2-06.jar:2.11.2-06] at org.sonatype.nexus.threads.MDCAwareCallable.call(MDCAwareCallable.java:44) [nexus-core-2.11.2-06.jar:2.11.2-06] at org.apache.shiro.subject.support.SubjectCallable.doCall(SubjectCallable.java:90) [shiro-core-1.2.3.jar:1.2.3] at org.apache.shiro.subject.support.SubjectCallable.call(SubjectCallable.java:83) [shiro-core-1.2.3.jar:1.2.3] at java.util.concurrent.FutureTask.run(FutureTask.java:262) [na:1.7.0_45] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:178) [na:1.7.0_45] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:292) [na:1.7.0_45] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [na:1.7.0_45] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [na:1.7.0_45] at java.lang.Thread.run(Thread.java:744) [na:1.7.0_45] 2015-05-07 11:14:42,340-0400 INFO [pxpool-1-thread-1] admin org.sonatype.nexus.configuration.application.DefaultNexusConfiguration - Applying Nexus Configuration due to changes in [Scheduled Tasks] made by *TASK... {noformat} Expected: do better preventing this commonly reproducible concurrency issue

    Sonatype JIRA | 2 years ago | Peter Lynch
    com.orientechnologies.orient.core.exception.OConcurrentModificationException: Cannot UPDATE the record #9:293 because the version is not the latest. Probably you are updating an old record or it has been modified by another user (db=v6 your=v5)
  2. 0

    NPE on move Records To Secondary Cache

    GitHub | 2 years ago | azzazeli
    com.orientechnologies.orient.core.exception.OConcurrentModificationException: Cannot UPDATE the record #9:104667 because the version is not the latest. Probably you are updating an old record or it has been modified by another user (db=v15 your=v14)
  3. 0

    CONFLICTSTRATEGY - automerge

    GitHub | 2 years ago | lvca
    com.orientechnologies.orient.core.exception.OConcurrentModificationException: Cannot UPDATE the record #197:4 because the version is not the latest. Probably you are updating an old record or it has been modified by another user (db=v5 your=v4)
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    OConcurrentModificationException while creating relations between verticies

    GitHub | 2 years ago | profic
    com.orientechnologies.orient.core.exception.OConcurrentModificationException: Cannot UPDATE the record #32:2 because the version is not the latest. Probably you are updating an old record or it has been modified by another user (db=v62 your=v61)
  6. 0

    conflictStrategy 'content' still throwing version exception - 2.0 SNAPSHOT

    Google Groups | 2 years ago | hihim...@gmail.com
    com.orientechnologies.orient.core.exception.OConcurrentModificationException: Cannot UPDATE the record #17:0 because the version is not the latest. Probably you are updating an old record or it has been modified by another user (db=v312 your=v311)

    1 unregistered visitors
    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. com.orientechnologies.orient.core.exception.OConcurrentModificationException

      Cannot UPDATE the record #9:293 because the version is not the latest. Probably you are updating an old record or it has been modified by another user (db=v6 your=v5)

      at com.orientechnologies.orient.core.conflict.OVersionRecordConflictStrategy.checkVersions()
    2. OrientDB Core
      ODatabaseDocumentTx.commit
      1. com.orientechnologies.orient.core.conflict.OVersionRecordConflictStrategy.checkVersions(OVersionRecordConflictStrategy.java:54)[na:na]
      2. com.orientechnologies.orient.core.conflict.OVersionRecordConflictStrategy.onUpdate(OVersionRecordConflictStrategy.java:41)[na:na]
      3. com.orientechnologies.orient.core.storage.impl.local.OAbstractPaginatedStorage.checkAndIncrementVersion(OAbstractPaginatedStorage.java:2009)[na:na]
      4. com.orientechnologies.orient.core.storage.impl.local.OAbstractPaginatedStorage.doUpdateRecord(OAbstractPaginatedStorage.java:1643)[na:na]
      5. com.orientechnologies.orient.core.storage.impl.local.OAbstractPaginatedStorage.commitEntry(OAbstractPaginatedStorage.java:2094)[na:na]
      6. com.orientechnologies.orient.core.storage.impl.local.OAbstractPaginatedStorage.commit(OAbstractPaginatedStorage.java:910)[na:na]
      7. com.orientechnologies.orient.core.tx.OTransactionOptimistic.doCommit(OTransactionOptimistic.java:483)[na:na]
      8. com.orientechnologies.orient.core.tx.OTransactionOptimistic.commit(OTransactionOptimistic.java:147)[na:na]
      9. com.orientechnologies.orient.core.db.document.ODatabaseDocumentTx.commit(ODatabaseDocumentTx.java:2370)[na:na]
      10. com.orientechnologies.orient.core.db.document.ODatabaseDocumentTx.commit(ODatabaseDocumentTx.java:2340)[na:na]
      10 frames
    3. com.bolyuba.nexus
      DefaultNpmProxyRepository.doExpireProxyCaches
      1. com.bolyuba.nexus.plugin.npm.service.internal.orient.OrientMetadataStore.updatePackages(OrientMetadataStore.java:334)[na:na]
      2. com.bolyuba.nexus.plugin.npm.service.internal.ProxyMetadataServiceImpl.expireMetadataCaches(ProxyMetadataServiceImpl.java:83)[na:na]
      3. com.bolyuba.nexus.plugin.npm.proxy.DefaultNpmProxyRepository.doExpireProxyCaches(DefaultNpmProxyRepository.java:150)[na:na]
      3 frames
    4. ${project.groupId}:${project.artifactId}
      AbstractNexusTask.call
      1. org.sonatype.nexus.proxy.repository.AbstractProxyRepository.doExpireCaches(AbstractProxyRepository.java:356)[nexus-core-2.11.2-06.jar:2.11.2-06]
      2. org.sonatype.nexus.proxy.repository.AbstractRepository.expireCaches(AbstractRepository.java:430)[nexus-core-2.11.2-06.jar:2.11.2-06]
      3. org.sonatype.nexus.proxy.repository.AbstractGroupRepository.doExpireCaches(AbstractGroupRepository.java:133)[nexus-core-2.11.2-06.jar:2.11.2-06]
      4. org.sonatype.nexus.proxy.repository.AbstractRepository.expireCaches(AbstractRepository.java:430)[nexus-core-2.11.2-06.jar:2.11.2-06]
      5. org.sonatype.nexus.proxy.repository.AbstractRepository.expireCaches(AbstractRepository.java:421)[nexus-core-2.11.2-06.jar:2.11.2-06]
      6. org.sonatype.nexus.tasks.ExpireCacheTask.doRun(ExpireCacheTask.java:51)[nexus-core-2.11.2-06.jar:2.11.2-06]
      7. org.sonatype.nexus.scheduling.AbstractNexusTask.call(AbstractNexusTask.java:151)[nexus-core-2.11.2-06.jar:2.11.2-06]
      7 frames
    5. ${project.groupId}:${project.artifactId}
      DefaultScheduledTask.call
      1. org.sonatype.scheduling.DefaultScheduledTask.call(DefaultScheduledTask.java:418)[nexus-scheduler-2.11.2-06.jar:2.11.2-06]
      1 frame
    6. ${project.groupId}:${project.artifactId}
      MDCAwareCallable.call
      1. org.sonatype.nexus.threads.MDCAwareCallable.call(MDCAwareCallable.java:44)[nexus-core-2.11.2-06.jar:2.11.2-06]
      1 frame
    7. Shiro
      SubjectCallable.call
      1. org.apache.shiro.subject.support.SubjectCallable.doCall(SubjectCallable.java:90)[shiro-core-1.2.3.jar:1.2.3]
      2. org.apache.shiro.subject.support.SubjectCallable.call(SubjectCallable.java:83)[shiro-core-1.2.3.jar:1.2.3]
      2 frames
    8. Java RT
      Thread.run
      1. java.util.concurrent.FutureTask.run(FutureTask.java:262)[na:1.7.0_45]
      2. java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:178)[na:1.7.0_45]
      3. java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:292)[na:1.7.0_45]
      4. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)[na:1.7.0_45]
      5. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)[na:1.7.0_45]
      6. java.lang.Thread.run(Thread.java:744)[na:1.7.0_45]
      6 frames