Vladislav Pyatkov created IGNITE-13072: ------------------------------------------
Summary: Synchronization problems when different classloaders are used for deployment of same class Key: IGNITE-13072 URL: https://issues.apache.org/jira/browse/IGNITE-13072 Project: Ignite Issue Type: Bug Reporter: Vladislav Pyatkov Assignee: Vladislav Pyatkov If you concurrently deploy one class using different classloaders you can get error: {noformat} 2020-04-28 14:36:42.523[ERROR][sys-stripe-45-#46%GRID%GridNodeName%][o.a.i.i.m.d.GridDeploymentLocalStore] Found more than one active deployment for the same resource [cls=class org.some.class.old.InvokeIndexRemover, depMode=SHARED, dep=GridDeployment [ts=1588067100125, depMode=SHARED, clsLdr=org.some.class.factory.NodeClassLoader@14035d21, clsLdrId=85ab310c171-a9fad11c-9f8c-4d2a-8146-6c87254303e7, userVer=0, loc=true, sampleClsName=org.some.class.predicates.CompositePredicate, pendingUndeploy=false, undeployed=false, usage=0]] 2020-04-28 14:36:42.544[ERROR][sys-stripe-45-#46%GRID%GridNodeName%][o.a.i.i.p.cache.GridCacheIoManager] Failed to process message [senderId=f104e069-9d80-4202-b50a-b3dc1804ac89, msg=GridNearAtomicSingleUpdateRequest [key=KeyCacheObject [hasValBytes=true], super=GridNearAtomicSingleUpdateRequest [key=KeyCacheObject [hasValBytes=true], parent=GridNearAtomicAbstractSingleUpdateRequest [nodeId=null, futId=1376257, topVer=AffinityTopologyVersion [topVer=35, minorTopVer=0], parent=GridNearAtomicAbstractUpdateRequest [res=null, flags=]]]]] java.lang.AssertionError: null at org.apache.ignite.internal.managers.deployment.GridDeploymentLocalStore.getDeployment(GridDeploymentLocalStore.java:203) at org.apache.ignite.internal.managers.deployment.GridDeploymentManager.getLocalDeployment(GridDeploymentManager.java:383) at org.apache.ignite.internal.processors.cache.GridCacheDeploymentManager$CacheClassLoader.findClass(GridCacheDeploymentManager.java:802) at org.apache.ignite.internal.processors.cache.GridCacheDeploymentManager$CacheClassLoader.loadClass(GridCacheDeploymentManager.java:794) at org.apache.ignite.internal.util.IgniteUtils.forName(IgniteUtils.java:8561) at org.apache.ignite.internal.MarshallerContextImpl.getClass(MarshallerContextImpl.java:374) at org.apache.ignite.internal.binary.BinaryContext.descriptorForTypeId(BinaryContext.java:700) at org.apache.ignite.internal.binary.BinaryReaderExImpl.deserialize0(BinaryReaderExImpl.java:1757) at org.apache.ignite.internal.binary.BinaryReaderExImpl.deserialize(BinaryReaderExImpl.java:1716) at org.apache.ignite.internal.binary.GridBinaryMarshaller.deserialize(GridBinaryMarshaller.java:313) at org.apache.ignite.internal.binary.BinaryMarshaller.unmarshal0(BinaryMarshaller.java:99) at org.apache.ignite.marshaller.AbstractNodeNameAwareMarshaller.unmarshal(AbstractNodeNameAwareMarshaller.java:82) at org.apache.ignite.internal.util.IgniteUtils.unmarshal(IgniteUtils.java:9959) at org.apache.ignite.internal.util.IgniteUtils.unmarshal(IgniteUtils.java:10017) at org.apache.ignite.internal.processors.cache.distributed.dht.atomic.GridNearAtomicSingleUpdateInvokeRequest.finishUnmarshal(GridNearAtomicSingleUpdateInvokeRequest.java:200) at org.apache.ignite.internal.processors.cache.GridCacheIoManager.unmarshall(GridCacheIoManager.java:1560) at org.apache.ignite.internal.processors.cache.GridCacheIoManager.onMessage0(GridCacheIoManager.java:582) at org.apache.ignite.internal.processors.cache.GridCacheIoManager.handleMessage(GridCacheIoManager.java:386) at org.apache.ignite.internal.processors.cache.GridCacheIoManager.handleMessage(GridCacheIoManager.java:312) at org.apache.ignite.internal.processors.cache.GridCacheIoManager.access$100(GridCacheIoManager.java:102) at org.apache.ignite.internal.processors.cache.GridCacheIoManager$1.onMessage(GridCacheIoManager.java:301) at org.apache.ignite.internal.managers.communication.GridIoManager.invokeListener(GridIoManager.java:1556) at org.apache.ignite.internal.managers.communication.GridIoManager.processRegularMessage0(GridIoManager.java:1184) at org.apache.ignite.internal.managers.communication.GridIoManager.access$4200(GridIoManager.java:125) at org.apache.ignite.internal.managers.communication.GridIoManager$9.run(GridIoManager.java:1091) at org.apache.ignite.internal.util.StripedExecutor$Stripe.body(StripedExecutor.java:546) at org.apache.ignite.internal.util.worker.GridWorker.run(GridWorker.java:120) at java.lang.Thread.run(Thread.java:748) {noformat} Looks like we lack synchronization for modifying {{LocalDeploymentSpi.ldrRsrcs}}. -- This message was sent by Atlassian Jira (v8.3.4#803005)