]
Dan Berindei commented on ISPN-10966:
-------------------------------------
Example failure stack trace
{noformat}
java.lang.RuntimeException: Test timed out after 300 seconds
at
java.base@11.0.3/java.util.concurrent.CompletableFuture.uniWhenComplete(CompletableFuture.java:859)
at
java.base@11.0.3/java.util.concurrent.CompletableFuture.uniWhenCompleteStage(CompletableFuture.java:883)
at
java.base@11.0.3/java.util.concurrent.CompletableFuture.whenComplete(CompletableFuture.java:2251)
at
java.base@11.0.3/java.util.concurrent.CompletableFuture.whenComplete(CompletableFuture.java:143)
at
app//org.infinispan.reactive.RxJavaInterop.completionStageToCompletable(RxJavaInterop.java:70)
at
app//org.infinispan.reactive.publisher.impl.ClusterPublisherManagerImpl$SubscriberHandler.lambda$start$1(ClusterPublisherManagerImpl.java:883)
at
app//org.infinispan.reactive.publisher.impl.ClusterPublisherManagerImpl$SubscriberHandler$$Lambda$846/0x0000000100872040.apply(Unknown
Source)
at
app//io.reactivex.internal.operators.flowable.FlowableScalarXMap$ScalarXMapFlowable.subscribeActual(FlowableScalarXMap.java:138)
at app//io.reactivex.Flowable.subscribe(Flowable.java:14918)
at app//io.reactivex.Flowable.subscribe(Flowable.java:14865)
at
app//io.reactivex.internal.operators.flowable.FlowableRepeatUntil$RepeatSubscriber.subscribeNext(FlowableRepeatUntil.java:109)
at
app//io.reactivex.internal.operators.flowable.FlowableRepeatUntil$RepeatSubscriber.onComplete(FlowableRepeatUntil.java:88)
at
app//io.reactivex.internal.observers.SubscriberCompletableObserver.onComplete(SubscriberCompletableObserver.java:33)
at app//io.reactivex.subjects.CompletableSubject.onComplete(CompletableSubject.java:139)
at
app//org.infinispan.reactive.RxJavaInterop.lambda$completionStageToCompletable$0(RxJavaInterop.java:74)
at
app//org.infinispan.reactive.RxJavaInterop$$Lambda$2360/0x0000000100c04040.accept(Unknown
Source)
at
java.base@11.0.3/java.util.concurrent.CompletableFuture.uniWhenComplete(CompletableFuture.java:859)
at
java.base@11.0.3/java.util.concurrent.CompletableFuture$UniWhenComplete.tryFire(CompletableFuture.java:837)
at
java.base@11.0.3/java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:506)
at
java.base@11.0.3/java.util.concurrent.CompletableFuture.complete(CompletableFuture.java:2073)
at
app//org.infinispan.statetransfer.StateTransferLockImpl.notifyTopologyInstalled(StateTransferLockImpl.java:133)
at
app//org.infinispan.statetransfer.StateTransferLockImpl.stop(StateTransferLockImpl.java:38)
at app//org.infinispan.statetransfer.CorePackageImpl$4.stop(CorePackageImpl.java:155)
at app//org.infinispan.statetransfer.CorePackageImpl$4.stop(CorePackageImpl.java:153)
at
app//org.infinispan.factories.impl.BasicComponentRegistryImpl.invokeStop(BasicComponentRegistryImpl.java:648)
at
app//org.infinispan.factories.impl.BasicComponentRegistryImpl.doStopWrapper(BasicComponentRegistryImpl.java:644)
at
app//org.infinispan.factories.impl.BasicComponentRegistryImpl.stopWrapper(BasicComponentRegistryImpl.java:632)
at
app//org.infinispan.factories.impl.BasicComponentRegistryImpl.stop(BasicComponentRegistryImpl.java:499)
at
app//org.infinispan.factories.AbstractComponentRegistry.internalStop(AbstractComponentRegistry.java:364)
at
app//org.infinispan.factories.AbstractComponentRegistry.stop(AbstractComponentRegistry.java:298)
at
app//org.infinispan.cache.impl.CacheImpl.performImmediateShutdown(CacheImpl.java:1140)
at app//org.infinispan.cache.impl.CacheImpl.stop(CacheImpl.java:1105)
at
app//org.infinispan.cache.impl.AbstractDelegatingCache.stop(AbstractDelegatingCache.java:522)
at
app//org.infinispan.manager.DefaultCacheManager.terminate(DefaultCacheManager.java:781)
at
app//org.infinispan.manager.DefaultCacheManager.stopCaches(DefaultCacheManager.java:837)
at
app//org.infinispan.manager.DefaultCacheManager.internalStop(DefaultCacheManager.java:813)
at app//org.infinispan.manager.DefaultCacheManager.stop(DefaultCacheManager.java:789)
at
app//org.infinispan.test.SecurityActions.lambda$stopManager$0(SecurityActions.java:35)
at app//org.infinispan.test.SecurityActions$$Lambda$989/0x00000001008c8840.run(Unknown
Source)
at app//org.infinispan.security.Security.doPrivileged(Security.java:47)
at app//org.infinispan.test.SecurityActions.doPrivileged(SecurityActions.java:29)
at app//org.infinispan.test.SecurityActions.stopManager(SecurityActions.java:34)
at app//org.infinispan.test.TestingUtil.killCacheManagers(TestingUtil.java:833)
at
app//org.infinispan.test.MultipleCacheManagersTest.clearContent(MultipleCacheManagersTest.java:159)
{noformat}
StateTransferLockImpl.topologyFuture should complete exceptionally
after stop
-----------------------------------------------------------------------------
Key: ISPN-10966
URL:
https://issues.jboss.org/browse/ISPN-10966
Project: Infinispan
Issue Type: Bug
Components: Core
Affects Versions: 10.1.0.Beta1
Reporter: Dan Berindei
Assignee: Dan Berindei
Priority: Major
Fix For: 10.1.0.CR1
When a cache is shutting down, the topology id is increased to {{Integer.MAX_VALUE}}.
If a component uses {{StateTransferLock.topologyUpdate()}} to retry in the next topology
and doesn't explicitly check if the cache is running, it could retry 2^^31 times
before giving up.
This causes {{StreamDistPartitionHandlingTest.clearContent}} to hang randomly:
{noformat}
11:58:14,655 TRACE (testng-Test:[]) [StateTransferLockImpl] Signalling topology
2147483647 is installed
11:58:14,655 TRACE (testng-Test:[]) [ClusterPublisherManagerImpl] Segments {0-3 8 12
21-22 25-26 29 31 35 37-39 41-42 47 52-54 56-58 73-75 77 85 93-95 97-99 104-105 107 118
121-122 126-129 133 140 145 149 151-154 161 167-168 170-171 177-178 186 189-190 195-196
199-205 212-214 216-217 221-222 224 226-227 232-233 243-244} not completed - retrying
11:58:14,655 TRACE (testng-Test:[]) [ClusterPublisherManagerImpl] Retrying segments {0-3
8 12 21-22 25-26 29 31 35 37-39 41-42 47 52-54 56-58 73-75 77 85 93-95 97-99 104-105 107
118 121-122 126-129 133 140 145 149 151-154 161 167-168 170-171 177-178 186 189-190
195-196 199-205 212-214 216-217 221-222 224 226-227 232-233 243-244} after 16 is installed
for Test-NodeA-12596#7046
...
12:03:16,127 TRACE (testng-Test:[]) [ClusterPublisherManagerImpl] Segments {0-3 8 12
21-22 25-26 29 31 35 37-39 41-42 47 52-54 56-58 73-75 77 85 93-95 97-99 104-105 107 118
121-122 126-129 133 140 145 149 151-154 161 167-168 170-171 177-178 186 189-190 195-196
199-205 212-214 216-217 221-222 224 226-227 232-233 243-244} not completed - retrying
12:03:16,127 TRACE (testng-Test:[]) [ClusterPublisherManagerImpl] Retrying segments {0-3
8 12 21-22 25-26 29 31 35 37-39 41-42 47 52-54 56-58 73-75 77 85 93-95 97-99 104-105 107
118 121-122 126-129 133 140 145 149 151-154 161 167-168 170-171 177-178 186 189-190
195-196 199-205 212-214 216-217 221-222 224 226-227 232-233 243-244} after 16 is installed
for Test-NodeA-12596#7046
...
{noformat}