diff --git a/modules/checkstyle/src/main/resources/abbrevations.csv b/modules/checkstyle/src/main/resources/abbrevations.csv index d51d1ded1c80f..e1969ffde81c6 100644 --- a/modules/checkstyle/src/main/resources/abbrevations.csv +++ b/modules/checkstyle/src/main/resources/abbrevations.csv @@ -24,8 +24,8 @@ event,evt events,evts exception,e,e2,ex execute,exec -#frequency,freq -#future,fut +frequency,freq +future,fut #group,grp #handler,hnd #header,hdr diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheAffinitySharedManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheAffinitySharedManager.java index 94e880b0755d3..6b997cb1a1415 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheAffinitySharedManager.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheAffinitySharedManager.java @@ -1988,7 +1988,7 @@ public IgniteInternalFuture initCoordinatorCaches( assert idx >= 0 && idx < exchFuts.size() - 1 : "Invalid exchange futures state [cur=" + idx + ", total=" + exchFuts.size() + ']'; - GridDhtPartitionsExchangeFuture futureToFetchAff = null; + GridDhtPartitionsExchangeFuture futToFetchAff = null; for (int i = idx + 1; i < exchFuts.size(); i++) { GridDhtPartitionsExchangeFuture prev = exchFuts.get(i); @@ -1998,40 +1998,40 @@ public IgniteInternalFuture initCoordinatorCaches( if (prev.isMerged()) continue; - futureToFetchAff = prev; + futToFetchAff = prev; break; } - if (futureToFetchAff == null) + if (futToFetchAff == null) throw new IgniteCheckedException("Failed to find completed exchange future to fetch affinity."); if (log.isDebugEnabled()) { log.debug("Need initialize affinity on coordinator [" + "cacheGrp=" + desc.cacheOrGroupName() + - "prevAff=" + futureToFetchAff.topologyVersion() + ']'); + "prevAff=" + futToFetchAff.topologyVersion() + ']'); } GridDhtAssignmentFetchFuture fetchFut = new GridDhtAssignmentFetchFuture( cctx, desc.groupId(), - futureToFetchAff.topologyVersion(), - futureToFetchAff.events().discoveryCache() + futToFetchAff.topologyVersion(), + futToFetchAff.events().discoveryCache() ); fetchFut.init(false); final GridFutureAdapter affFut = new GridFutureAdapter<>(); - final GridDhtPartitionsExchangeFuture futureToFetchAffinity0 = futureToFetchAff; + final GridDhtPartitionsExchangeFuture futToFetchAffinity0 = futToFetchAff; fetchFut.listen(new IgniteInClosureX>() { @Override public void applyx(IgniteInternalFuture fetchFut) throws IgniteCheckedException { fetchAffinity( - futureToFetchAffinity0.topologyVersion(), - futureToFetchAffinity0.events(), - futureToFetchAffinity0.events().discoveryCache(), + futToFetchAffinity0.topologyVersion(), + futToFetchAffinity0.events(), + futToFetchAffinity0.events().discoveryCache(), aff, (GridDhtAssignmentFetchFuture)fetchFut ); diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GatewayProtectedCacheProxy.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GatewayProtectedCacheProxy.java index 5641c733a1122..74713f6dbfdc2 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GatewayProtectedCacheProxy.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GatewayProtectedCacheProxy.java @@ -1380,17 +1380,17 @@ public void setCacheManager(org.apache.ignite.cache.CacheManager cacheMgr) { if (!onEnterIfNoStop(gate)) return; - IgniteFuture destroyFuture; + IgniteFuture destroyFut; try { - destroyFuture = delegate.destroyAsync(); + destroyFut = delegate.destroyAsync(); } finally { onLeave(gate); } - if (destroyFuture != null) - destroyFuture.get(); + if (destroyFut != null) + destroyFut.get(); } /** {@inheritDoc} */ @@ -1405,17 +1405,17 @@ public void setCacheManager(org.apache.ignite.cache.CacheManager cacheMgr) { if (!onEnterIfNoStop(gate)) return; - IgniteFuture closeFuture; + IgniteFuture closeFut; try { - closeFuture = closeAsync(); + closeFut = closeAsync(); } finally { onLeave(gate); } - if (closeFuture != null) - closeFuture.get(); + if (closeFut != null) + closeFut.get(); } /** {@inheritDoc} */ diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java index 53fa60f079c7f..94e4d2d741b8b 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java @@ -4796,10 +4796,10 @@ else if (res.resultType() == ResultType.FILTERED) { else if (res.resultType() == ResultType.LOCKED) { entry.unlockEntry(); - IgniteInternalFuture lockFuture = + IgniteInternalFuture lockFut0 = cctx.kernalContext().coordinators().waitForLock(cctx, mvccVer, res.resultVersion()); - lockFuture.listen(this); + lockFut0.listen(this); return; } diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java index 8bbde4d062381..9ca503678031b 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java @@ -332,10 +332,10 @@ public IgniteInternalFuture finishRemoteTxs(AffinityTopologyVersion topVer) { for (GridCacheFuture fut : futs.values()) { if (fut instanceof GridDhtTxFinishFuture) { - GridDhtTxFinishFuture finishTxFuture = (GridDhtTxFinishFuture)fut; + GridDhtTxFinishFuture finishTxFut = (GridDhtTxFinishFuture)fut; - if (cctx.tm().needWaitTransaction(finishTxFuture.tx(), topVer)) - res.add(ignoreErrors(finishTxFuture)); + if (cctx.tm().needWaitTransaction(finishTxFut.tx(), topVer)) + res.add(ignoreErrors(finishTxFut)); } } diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSharedContext.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSharedContext.java index 7d87015854b88..4511c0d9df1ef 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSharedContext.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSharedContext.java @@ -966,10 +966,10 @@ public IgniteInternalFuture partitionReleaseFuture(AffinityTopologyVersion to f.add(mvcc().finishAtomicUpdates(topVer)); f.add(mvcc().finishDataStreamerUpdates(topVer)); - IgniteInternalFuture finishLocalTxsFuture = tm().finishLocalTxs(topVer); + IgniteInternalFuture finishLocalTxsFut = tm().finishLocalTxs(topVer); // To properly track progress of finishing local tx updates we explicitly add this future to compound set. - f.add(finishLocalTxsFuture); - f.add(tm().finishAllTxs(finishLocalTxsFuture, topVer)); + f.add(finishLocalTxsFut); + f.add(tm().finishAllTxs(finishLocalTxsFut, topVer)); f.markInitialized(); diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/snapshot/IgniteSnapshotManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/snapshot/IgniteSnapshotManager.java index e6f3fb635e6d6..c07a7e5b950f5 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/snapshot/IgniteSnapshotManager.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/snapshot/IgniteSnapshotManager.java @@ -3785,9 +3785,9 @@ public synchronized void acceptFile(File part) { if (o == null || getClass() != o.getClass()) return false; - RemoteSnapshotFilesRecevier future = (RemoteSnapshotFilesRecevier)o; + RemoteSnapshotFilesRecevier fut = (RemoteSnapshotFilesRecevier)o; - return Objects.equals(reqId, future.reqId); + return Objects.equals(reqId, fut.reqId); } /** {@inheritDoc} */ diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/snapshot/SnapshotRestoreProcess.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/snapshot/SnapshotRestoreProcess.java index e8bca0bed88a1..1710a5f587ec8 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/snapshot/SnapshotRestoreProcess.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/snapshot/SnapshotRestoreProcess.java @@ -2037,9 +2037,9 @@ private PartitionRestoreFuture(int partId, AtomicInteger cntr) { if (o == null || getClass() != o.getClass()) return false; - PartitionRestoreFuture future = (PartitionRestoreFuture)o; + PartitionRestoreFuture fut = (PartitionRestoreFuture)o; - return partId == future.partId; + return partId == fut.partId; } /** {@inheritDoc} */ diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/datastructures/GridCacheSemaphoreImpl.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/datastructures/GridCacheSemaphoreImpl.java index 0275dcfb27734..2212c32fc626a 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/datastructures/GridCacheSemaphoreImpl.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/datastructures/GridCacheSemaphoreImpl.java @@ -674,12 +674,12 @@ private void initializeSemaphore() throws IgniteCheckedException { int numPermits) { acquire(numPermits); - Future passedInCallableFuture = ctx.kernalContext().pools().getExecutorService().submit(callable); + Future passedInCallableFut = ctx.kernalContext().pools().getExecutorService().submit(callable); final GridFutureAdapter fut = new GridFutureAdapter() { @Override public T get() { try { - return passedInCallableFuture.get(); + return passedInCallableFut.get(); } catch (Exception e) { throw new RuntimeException(e.getMessage()); @@ -687,16 +687,16 @@ private void initializeSemaphore() throws IgniteCheckedException { } }; - IgniteFuture future = new IgniteFutureImpl<>(fut); + IgniteFuture fut0 = new IgniteFutureImpl<>(fut); - future.listen(new IgniteInClosure>() { + fut0.listen(new IgniteInClosure>() { /** {@inheritDoc} */ @Override public void apply(IgniteFuture igniteFuture) { release(numPermits); } }); - return future; + return fut0; } /** {@inheritDoc} */ diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/compute/PlatformCompute.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/compute/PlatformCompute.java index 65ae6ae9774b0..90fe4ff28c40e 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/compute/PlatformCompute.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/compute/PlatformCompute.java @@ -193,9 +193,9 @@ private PlatformCompute( PlatformCallable callable = new PlatformCallable(func, ptr, funcName); - IgniteInternalFuture future = compute.affinityCallAsync(cacheNames, part, callable); + IgniteInternalFuture fut = compute.affinityCallAsync(cacheNames, part, callable); - return wrapListenable(readAndListenFuture(reader, future)); + return wrapListenable(readAndListenFuture(reader, fut)); } case OP_AFFINITY_CALL: { @@ -207,9 +207,9 @@ private PlatformCompute( PlatformCallable callable = new PlatformCallable(func, ptr, callableName); - IgniteInternalFuture future = compute.affinityCallAsync(Collections.singletonList(cacheName), key, callable); + IgniteInternalFuture fut = compute.affinityCallAsync(Collections.singletonList(cacheName), key, callable); - return wrapListenable(readAndListenFuture(reader, future)); + return wrapListenable(readAndListenFuture(reader, fut)); } case OP_AFFINITY_RUN_PARTITION: { @@ -221,9 +221,9 @@ private PlatformCompute( PlatformRunnable runnable = new PlatformRunnable(func, ptr, runnableName); - IgniteInternalFuture future = compute.affinityRunAsync(cacheNames, part, runnable); + IgniteInternalFuture fut = compute.affinityRunAsync(cacheNames, part, runnable); - return wrapListenable(readAndListenFuture(reader, future)); + return wrapListenable(readAndListenFuture(reader, fut)); } case OP_AFFINITY_RUN: { @@ -235,9 +235,9 @@ private PlatformCompute( PlatformRunnable runnable = new PlatformRunnable(func, ptr, runnableName); - IgniteInternalFuture future = compute.affinityRunAsync(Collections.singleton(cacheName), key, runnable); + IgniteInternalFuture fut = compute.affinityRunAsync(Collections.singleton(cacheName), key, runnable); - return wrapListenable(readAndListenFuture(reader, future)); + return wrapListenable(readAndListenFuture(reader, fut)); } default: diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/IgniteStatisticsConfigurationManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/IgniteStatisticsConfigurationManager.java index 0c804ece39f82..feaf82ee49512 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/IgniteStatisticsConfigurationManager.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/IgniteStatisticsConfigurationManager.java @@ -373,18 +373,18 @@ public void start() { */ public void updateAllLocalStatistics() { try { - GridCompoundFuture compoundFuture = new GridCompoundFuture<>(CU.boolReducer()); + GridCompoundFuture compoundFut = new GridCompoundFuture<>(CU.boolReducer()); distrMetaStorage.iterate(STAT_OBJ_PREFIX, (k, v) -> { StatisticsObjectConfiguration cfg = (StatisticsObjectConfiguration)v; - compoundFuture.add(updateLocalStatisticsAsync(cfg)); + compoundFut.add(updateLocalStatisticsAsync(cfg)); }); - compoundFuture.markInitialized(); + compoundFut.markInitialized(); - compoundFuture.listen(() -> { - if (compoundFuture.error() == null && !compoundFuture.result()) + compoundFut.listen(() -> { + if (compoundFut.error() == null && !compoundFut.result()) mgmtBusyExecutor.execute(this::updateAllLocalStatistics); }); } @@ -486,11 +486,11 @@ public IgniteInternalFuture dropStatisticsAsync(List if (log.isDebugEnabled()) log.debug("Drop statistics [targets=" + targets + ']'); - GridFutureAdapter resultFuture = new GridFutureAdapter<>(); - IgniteInternalFuture chainFuture = new GridFinishedFuture<>(true); + GridFutureAdapter resultFut = new GridFutureAdapter<>(); + IgniteInternalFuture chainFut = new GridFinishedFuture<>(true); for (StatisticsTarget target : targets) { - chainFuture = chainFuture.chainCompose(f -> { + chainFut = chainFut.chainCompose(f -> { if (f.error() == null && f.result() == Boolean.TRUE) return removeFromMetastore(target, validate); @@ -498,14 +498,14 @@ public IgniteInternalFuture dropStatisticsAsync(List }); } - chainFuture.listen(f -> { + chainFut.listen(f -> { if (f.error() != null) - resultFuture.onDone(f.error()); + resultFut.onDone(f.error()); else - resultFuture.onDone(f.result() == null || f.result().booleanValue()); + resultFut.onDone(f.result() == null || f.result().booleanValue()); }); - return resultFuture; + return resultFut; } /** diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/future/IgniteRemoteMapTask.java b/modules/core/src/main/java/org/apache/ignite/internal/util/future/IgniteRemoteMapTask.java index f8e4d7d664cb7..e2812569bc7fd 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/util/future/IgniteRemoteMapTask.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/util/future/IgniteRemoteMapTask.java @@ -120,13 +120,13 @@ public Job(ComputeTask remoteTask, @Nullable T arg) { compute.execute(remoteTask, arg); - ComputeTaskFuture future = compute.future(); + ComputeTaskFuture fut = compute.future(); - this.future = future; + this.future = fut; jobCtx.holdcc(); - future.listen(new IgniteInClosure>() { + fut.listen(new IgniteInClosure>() { @Override public void apply(IgniteFuture future) { jobCtx.callcc(); } diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridMultithreadedJobStealingSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridMultithreadedJobStealingSelfTest.java index 2ede9cbb4fc0b..57a1bb0c3dffd 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridMultithreadedJobStealingSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridMultithreadedJobStealingSelfTest.java @@ -185,7 +185,7 @@ public void testJoinedNodeCanStealJobs() throws Exception { jobExecutedLatch = new CountDownLatch(threadsNum); - final IgniteInternalFuture future = GridTestUtils.runMultiThreadedAsync(new Runnable() { + final IgniteInternalFuture fut = GridTestUtils.runMultiThreadedAsync(new Runnable() { /** * */ @@ -220,7 +220,7 @@ public void testJoinedNodeCanStealJobs() throws Exception { info("Metrics [nodeId=" + g.cluster().localNode().id() + ", metrics=" + g.cluster().localNode().metrics() + ']'); - future.get(); + fut.get(); assertNull("Test failed with exception: ", fail.get()); diff --git a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientCheckClusterGroupLocalIdAfterReconnect.java b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientCheckClusterGroupLocalIdAfterReconnect.java index 93a4673bbec39..d870d27b74c37 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientCheckClusterGroupLocalIdAfterReconnect.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientCheckClusterGroupLocalIdAfterReconnect.java @@ -117,11 +117,11 @@ public void testClusterGroupLocalIdAfterClientReconnect() throws Exception { startGrid(0); // wait for client reconnect - IgniteFuture future = client.cluster().clientReconnectFuture(); + IgniteFuture fut = client.cluster().clientReconnectFuture(); - assertNotNull(future); + assertNotNull(fut); - future.get(20_000); // throws if times out + fut.get(20_000); // throws if times out ClusterGroup cg2 = client.cluster().forLocal(); diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteClusterActivateDeactivateTestWithPersistence.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteClusterActivateDeactivateTestWithPersistence.java index fb3b26a280f97..16dcce9847686 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteClusterActivateDeactivateTestWithPersistence.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteClusterActivateDeactivateTestWithPersistence.java @@ -687,7 +687,7 @@ public void testDeactivateDuringEvictionAndRebalance() throws Exception { Set addedKeys = new GridConcurrentHashSet<>(); - IgniteInternalFuture cacheLoadFuture = GridTestUtils.runMultiThreadedAsync( + IgniteInternalFuture cacheLoadFut = GridTestUtils.runMultiThreadedAsync( () -> { while (!stop.get()) { int key = keyCounter.incrementAndGet(); @@ -718,7 +718,7 @@ public void testDeactivateDuringEvictionAndRebalance() throws Exception { stop.set(true); - cacheLoadFuture.get(); + cacheLoadFut.get(); // Deactivate and activate again. srv.cluster().state(INACTIVE); diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/datastructures/IgniteSemaphoreAbstractSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/datastructures/IgniteSemaphoreAbstractSelfTest.java index f683f868f10ec..ddd5b4b5bb10f 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/datastructures/IgniteSemaphoreAbstractSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/datastructures/IgniteSemaphoreAbstractSelfTest.java @@ -322,12 +322,12 @@ public void testAcquireAndExecute() throws Exception { } }; - IgniteFuture igniteFuture = semaphore.acquireAndExecute(callable, 1); + IgniteFuture igniteFut = semaphore.acquireAndExecute(callable, 1); Runnable runnable = new Runnable() { /** {@inheritDoc} */ @Override public void run() { - IgniteFutureImpl impl = (IgniteFutureImpl)igniteFuture; + IgniteFutureImpl impl = (IgniteFutureImpl)igniteFut; GridFutureAdapter fut = (GridFutureAdapter)(impl.internalFuture()); fut.onDone(true); @@ -337,9 +337,9 @@ public void testAcquireAndExecute() throws Exception { executorService.submit(runnable); Thread.sleep(1000); - igniteFuture.get(7000, MILLISECONDS); + igniteFut.get(7000, MILLISECONDS); - assertTrue(igniteFuture.isDone()); + assertTrue(igniteFut.isDone()); assertTrue(semaphore.availablePermits() == 1); @@ -364,14 +364,14 @@ public void testAcquireAndExecuteIfFailure() { GridTestUtils.assertThrows(log, new Callable() { @Override public Object call() throws Exception { - IgniteFuture igniteFuture = semaphore.acquireAndExecute(callable, 1); + IgniteFuture igniteFut = semaphore.acquireAndExecute(callable, 1); Runnable runnable = new Runnable() { /** {@inheritDoc} */ @Override public void run() { try { Thread.sleep(1000); - IgniteFutureImpl impl = (IgniteFutureImpl)igniteFuture; + IgniteFutureImpl impl = (IgniteFutureImpl)igniteFut; GridFutureAdapter fut = (GridFutureAdapter)(impl.internalFuture()); fut.onDone(true); @@ -384,9 +384,9 @@ public void testAcquireAndExecuteIfFailure() { executorService.submit(runnable); - ((IgniteFutureImpl)igniteFuture).internalFuture().get(); + ((IgniteFutureImpl)igniteFut).internalFuture().get(); - assertTrue(igniteFuture.isDone()); + assertTrue(igniteFut.isDone()); return null; } diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/CacheLateAffinityAssignmentTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/CacheLateAffinityAssignmentTest.java index 173cac6171bd7..8c0205592d4d7 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/CacheLateAffinityAssignmentTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/CacheLateAffinityAssignmentTest.java @@ -1748,7 +1748,7 @@ public void testDelayAssignmentAffinityChanged2() throws Exception { blockSupplySend(commSpi0, CACHE_NAME1); - final IgniteInternalFuture startedFuture = multithreadedAsync(new Callable() { + final IgniteInternalFuture startedFut = multithreadedAsync(new Callable() { @Override public Void call() throws Exception { startServer(3, 5); @@ -1762,12 +1762,12 @@ public void testDelayAssignmentAffinityChanged2() throws Exception { boolean started = waitForCondition(new GridAbsPredicate() { @Override public boolean apply() { - return startedFuture.isDone(); + return startedFut.isDone(); } }, 10_000); if (!started) - startedFuture.cancel(); + startedFut.cancel(); assertTrue(started); diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridCachePartitionsStateValidationTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridCachePartitionsStateValidationTest.java index 6f84a3905004a..d1a0b74c585dd 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridCachePartitionsStateValidationTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridCachePartitionsStateValidationTest.java @@ -167,7 +167,7 @@ public void testPartitionCountersConsistencyOnExchange() throws Exception { final AtomicBoolean stop = new AtomicBoolean(); // Run atomic load. - IgniteInternalFuture atomicLoadFuture = GridTestUtils.runMultiThreadedAsync(() -> { + IgniteInternalFuture atomicLoadFut = GridTestUtils.runMultiThreadedAsync(() -> { int k = 0; while (!stop.get()) { @@ -182,7 +182,7 @@ public void testPartitionCountersConsistencyOnExchange() throws Exception { }, 1, "atomic-load"); // Run tx load. - IgniteInternalFuture txLoadFuture = GridTestUtils.runMultiThreadedAsync(() -> { + IgniteInternalFuture txLoadFut = GridTestUtils.runMultiThreadedAsync(() -> { final int txOps = 5; while (!stop.get()) { @@ -210,7 +210,7 @@ public void testPartitionCountersConsistencyOnExchange() throws Exception { spi.blockFullMessage(); // Trigger exchange. - IgniteInternalFuture nodeStopFuture = GridTestUtils.runAsync(() -> stopGrid(3)); + IgniteInternalFuture nodeStopFut = GridTestUtils.runAsync(() -> stopGrid(3)); try { spi.waitUntilAllSingleMessagesAreSent(); @@ -243,9 +243,9 @@ public void testPartitionCountersConsistencyOnExchange() throws Exception { stop.set(true); - atomicLoadFuture.get(); - txLoadFuture.get(); - nodeStopFuture.get(); + atomicLoadFut.get(); + txLoadFut.get(); + nodeStopFut.get(); } // Return grid to initial state. diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCacheStartWithLoadTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCacheStartWithLoadTest.java index 8efd27054b64a..eab16c2f32e6d 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCacheStartWithLoadTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCacheStartWithLoadTest.java @@ -89,7 +89,7 @@ public void testNoRebalanceDuringCacheStart() throws Exception { AtomicInteger txLoaderNo = new AtomicInteger(0); - IgniteInternalFuture txLoadFuture = GridTestUtils.runMultiThreadedAsync(() -> { + IgniteInternalFuture txLoadFut = GridTestUtils.runMultiThreadedAsync(() -> { Ignite node = grid(txLoaderNo.getAndIncrement()); IgniteCache cache = node.cache(CACHE_NAME); ThreadLocalRandom rnd = ThreadLocalRandom.current(); @@ -119,7 +119,7 @@ public void testNoRebalanceDuringCacheStart() throws Exception { AtomicBoolean cacheRestartStop = new AtomicBoolean(); - IgniteInternalFuture cacheRestartFuture = GridTestUtils.runAsync(() -> { + IgniteInternalFuture cacheRestartFut = GridTestUtils.runAsync(() -> { Ignite node = grid(0); final String tmpCacheName = "tmp"; @@ -156,8 +156,8 @@ public void testNoRebalanceDuringCacheStart() throws Exception { cacheRestartStop.set(true); txLoadStop.set(true); - cacheRestartFuture.get(); - txLoadFuture.get(); + cacheRestartFut.get(); + txLoadFut.get(); Assert.assertFalse(hasRebalance.get()); } diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/rebalancing/CacheManualRebalancingTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/rebalancing/CacheManualRebalancingTest.java index 655e2c1f68861..d1a791e3cba43 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/rebalancing/CacheManualRebalancingTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/rebalancing/CacheManualRebalancingTest.java @@ -100,11 +100,11 @@ public void testRebalance() throws Exception { // Start manual rebalancing. IgniteCompute compute = newNode.compute(); - final IgniteFuture rebalanceTaskFuture = compute.broadcastAsync(new MyCallable()); + final IgniteFuture rebalanceTaskFut = compute.broadcastAsync(new MyCallable()); boolean rebalanceFinished = GridTestUtils.waitForCondition(new GridAbsPredicate() { @Override public boolean apply() { - return rebalanceTaskFuture.isDone(); + return rebalanceTaskFut.isDone(); } }, 10_000); diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/rebalancing/CacheRebalanceWithRemovedWalSegment.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/rebalancing/CacheRebalanceWithRemovedWalSegment.java index 7114fed77cab6..464457208fd70 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/rebalancing/CacheRebalanceWithRemovedWalSegment.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/rebalancing/CacheRebalanceWithRemovedWalSegment.java @@ -116,10 +116,10 @@ public void test() throws Exception { ignite.cluster().state(ClusterState.ACTIVE); - GridDhtPartitionsExchangeFuture exchangeFuture = ignite(0).context().cache().context().exchange().lastTopologyFuture(); + GridDhtPartitionsExchangeFuture exchangeFut = ignite(0).context().cache().context().exchange().lastTopologyFuture(); // Waiting for reservation, otherwise we can catch a problem during reservation. - exchangeFuture.get(); + exchangeFut.get(); TestRecordingCommunicationSpi.spi(ignite).waitForBlocked(); @@ -141,7 +141,7 @@ public void test() throws Exception { LogListener lsnr = LogListener.matches("Failed to continue supplying [grp=" + DEFAULT_CACHE_NAME + ", demander=" + ignite.localNode().id() - + ", topVer=" + exchangeFuture.topologyVersion() + ']').build(); + + ", topVer=" + exchangeFut.topologyVersion() + ']').build(); listeningLog.registerListener(lsnr); diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/IgnitePdsTaskCancelingTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/IgnitePdsTaskCancelingTest.java index 39263752079da..5e5e0819528f4 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/IgnitePdsTaskCancelingTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/IgnitePdsTaskCancelingTest.java @@ -152,8 +152,8 @@ public void testFailNodesOnCanceledTask() throws Exception { latch.await(); - for (IgniteFuture future: cancelFutures) - future.cancel(); + for (IgniteFuture fut: cancelFutures) + fut.cancel(); slowFileIoEnabled.set(false); diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/wal/aware/SegmentAwareTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/wal/aware/SegmentAwareTest.java index e81b8a4a233d1..7522c044503bc 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/wal/aware/SegmentAwareTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/wal/aware/SegmentAwareTest.java @@ -87,13 +87,13 @@ public void testFinishAwaitSegment_WhenExactWaitingSegmentWasSet() throws Ignite //given: thread which awaited segment. SegmentAware aware = segmentAware(10); - IgniteInternalFuture future = awaitThread(() -> aware.awaitSegment(5)); + IgniteInternalFuture fut = awaitThread(() -> aware.awaitSegment(5)); //when: set exact awaiting segment. aware.curAbsWalIdx(5); //then: waiting should finish immediately - future.get(20); + fut.get(20); } /** @@ -104,13 +104,13 @@ public void testFinishAwaitSegment_WhenGreaterThanWaitingSegmentWasSet() throws //given: thread which awaited segment. SegmentAware aware = segmentAware(10); - IgniteInternalFuture future = awaitThread(() -> aware.awaitSegment(5)); + IgniteInternalFuture fut = awaitThread(() -> aware.awaitSegment(5)); //when: set grater than awaiting segment. aware.curAbsWalIdx(10); //then: waiting should finish immediately - future.get(20); + fut.get(20); } /** @@ -121,19 +121,19 @@ public void testFinishAwaitSegment_WhenNextSegmentEqualToWaitingOne() throws Ign //given: thread which awaited segment. SegmentAware aware = segmentAware(10); - IgniteInternalFuture future = awaitThread(() -> aware.awaitSegment(5)); + IgniteInternalFuture fut = awaitThread(() -> aware.awaitSegment(5)); //when: set less than awaiting segment. aware.curAbsWalIdx(4); //then: thread still waiting the segment - assertFutureIsNotFinish(future); + assertFutureIsNotFinish(fut); //when: trigger next segment. aware.nextAbsoluteSegmentIndex(); //then: waiting should finish immediately - future.get(20); + fut.get(20); } /** @@ -144,13 +144,13 @@ public void testFinishAwaitSegment_WhenInterruptWasCall() throws IgniteCheckedEx //given: thread which awaited segment. SegmentAware aware = segmentAware(10); - IgniteInternalFuture future = awaitThread(() -> aware.awaitSegment(5)); + IgniteInternalFuture fut = awaitThread(() -> aware.awaitSegment(5)); //when: interrupt waiting. aware.interrupt(); //then: IgniteInterruptedCheckedException should be throw. - assertTrue(future.get(20) instanceof IgniteInterruptedCheckedException); + assertTrue(fut.get(20) instanceof IgniteInterruptedCheckedException); } /** @@ -164,13 +164,13 @@ public void testFinishWaitSegmentForArchive_WhenWorkSegmentIncremented() throws aware.curAbsWalIdx(5); aware.setLastArchivedAbsoluteIndex(4); - IgniteInternalFuture future = awaitThread(aware::waitNextSegmentForArchivation); + IgniteInternalFuture fut = awaitThread(aware::waitNextSegmentForArchivation); //when: next work segment triggered. aware.nextAbsoluteSegmentIndex(); //then: waiting should finish immediately. - future.get(20); + fut.get(20); } /** @@ -184,13 +184,13 @@ public void testFinishWaitSegmentForArchive_WhenWorkSegmentGreaterValue() throws aware.curAbsWalIdx(5); aware.setLastArchivedAbsoluteIndex(4); - IgniteInternalFuture future = awaitThread(aware::waitNextSegmentForArchivation); + IgniteInternalFuture fut = awaitThread(aware::waitNextSegmentForArchivation); //when: set work segment greater than required. aware.curAbsWalIdx(7); //then: waiting should finish immediately. - future.get(20); + fut.get(20); } /** @@ -204,13 +204,13 @@ public void testFinishWaitSegmentForArchive_WhenInterruptWasCall() throws Ignite aware.curAbsWalIdx(5); aware.setLastArchivedAbsoluteIndex(4); - IgniteInternalFuture future = awaitThread(aware::waitNextSegmentForArchivation); + IgniteInternalFuture fut = awaitThread(aware::waitNextSegmentForArchivation); //when: interrupt waiting. aware.interrupt(); //then: IgniteInterruptedCheckedException should be throw. - assertTrue(future.get(20) instanceof IgniteInterruptedCheckedException); + assertTrue(fut.get(20) instanceof IgniteInterruptedCheckedException); } /** @@ -241,13 +241,13 @@ public void testFinishWaitNextAbsoluteIndex_WhenMarkAsArchivedFirstSegment() thr aware.curAbsWalIdx(1); aware.setLastArchivedAbsoluteIndex(-1); - IgniteInternalFuture future = awaitThread(aware::nextAbsoluteSegmentIndex); + IgniteInternalFuture fut = awaitThread(aware::nextAbsoluteSegmentIndex); //when: mark first segment as moved. aware.markAsMovedToArchive(0); //then: waiting should finish immediately. - future.get(20); + fut.get(20); } /** @@ -261,13 +261,13 @@ public void testFinishWaitNextAbsoluteIndex_WhenSetToArchivedFirst() throws Igni aware.curAbsWalIdx(1); aware.setLastArchivedAbsoluteIndex(-1); - IgniteInternalFuture future = awaitThread(aware::nextAbsoluteSegmentIndex); + IgniteInternalFuture fut = awaitThread(aware::nextAbsoluteSegmentIndex); //when: mark first segment as moved. aware.setLastArchivedAbsoluteIndex(0); //then: waiting should finish immediately. - future.get(20); + fut.get(20); } /** @@ -281,19 +281,19 @@ public void testFinishWaitNextAbsoluteIndex_WhenOnlyForceInterruptWasCall() thro aware.curAbsWalIdx(2); aware.setLastArchivedAbsoluteIndex(-1); - IgniteInternalFuture future = awaitThread(aware::nextAbsoluteSegmentIndex); + IgniteInternalFuture fut = awaitThread(aware::nextAbsoluteSegmentIndex); //when: interrupt waiting. aware.interrupt(); //then: nothing to happen because nextAbsoluteSegmentIndex is not interrupt by "interrupt" call. - assertFutureIsNotFinish(future); + assertFutureIsNotFinish(fut); //when: force interrupt waiting. aware.forceInterrupt(); //then: IgniteInterruptedCheckedException should be throw. - assertTrue(future.get(20) instanceof IgniteInterruptedCheckedException); + assertTrue(fut.get(20) instanceof IgniteInterruptedCheckedException); } /** @@ -304,13 +304,13 @@ public void testFinishSegmentArchived_WhenSetExactWaitingSegment() throws Ignite //given: thread which awaited segment. SegmentAware aware = segmentAware(10); - IgniteInternalFuture future = awaitThread(() -> aware.awaitSegmentArchived(5)); + IgniteInternalFuture fut = awaitThread(() -> aware.awaitSegmentArchived(5)); //when: archived exact expected segment. aware.setLastArchivedAbsoluteIndex(5); //then: waiting should finish immediately. - future.get(20); + fut.get(20); } /** @@ -321,13 +321,13 @@ public void testFinishSegmentArchived_WhenMarkExactWaitingSegment() throws Ignit //given: thread which awaited segment. SegmentAware aware = segmentAware(10); - IgniteInternalFuture future = awaitThread(() -> aware.awaitSegmentArchived(5)); + IgniteInternalFuture fut = awaitThread(() -> aware.awaitSegmentArchived(5)); //when: mark exact segment as moved. aware.markAsMovedToArchive(5); //then: waiting should finish immediately. - future.get(20); + fut.get(20); } /** @@ -338,13 +338,13 @@ public void testFinishSegmentArchived_WhenSetGreaterThanWaitingSegment() throws //given: thread which awaited segment. SegmentAware aware = segmentAware(10); - IgniteInternalFuture future = awaitThread(() -> aware.awaitSegmentArchived(5)); + IgniteInternalFuture fut = awaitThread(() -> aware.awaitSegmentArchived(5)); //when: archived greater than expected segment. aware.setLastArchivedAbsoluteIndex(7); //then: waiting should finish immediately. - future.get(20); + fut.get(20); } /** @@ -355,13 +355,13 @@ public void testFinishSegmentArchived_WhenMarkGreaterThanWaitingSegment() throws //given: thread which awaited segment. SegmentAware aware = segmentAware(10); - IgniteInternalFuture future = awaitThread(() -> aware.awaitSegmentArchived(5)); + IgniteInternalFuture fut = awaitThread(() -> aware.awaitSegmentArchived(5)); //when: moved greater than expected segment. aware.markAsMovedToArchive(7); //then: waiting should finish immediately. - future.get(20); + fut.get(20); } /** @@ -375,13 +375,13 @@ public void testFinishSegmentArchived_WhenInterruptWasCall() throws IgniteChecke aware.curAbsWalIdx(5); aware.setLastArchivedAbsoluteIndex(4); - IgniteInternalFuture future = awaitThread(() -> aware.awaitSegmentArchived(5)); + IgniteInternalFuture fut = awaitThread(() -> aware.awaitSegmentArchived(5)); //when: interrupt waiting. aware.interrupt(); //then: IgniteInterruptedCheckedException should be throw. - assertTrue(future.get(20) instanceof IgniteInterruptedCheckedException); + assertTrue(fut.get(20) instanceof IgniteInterruptedCheckedException); } /** @@ -394,13 +394,13 @@ public void testMarkAsMovedToArchive_WhenReleaseLockedSegment() throws IgniteChe assertTrue(aware.lock(5)); - IgniteInternalFuture future = awaitThread(() -> aware.markAsMovedToArchive(5)); + IgniteInternalFuture fut = awaitThread(() -> aware.markAsMovedToArchive(5)); //when: release exact expected work segment. aware.unlock(5); //then: waiting should finish immediately. - future.get(20); + fut.get(20); } /** @@ -413,13 +413,13 @@ public void testMarkAsMovedToArchive_WhenInterruptWasCall() throws IgniteChecked assertTrue(aware.lock(5)); - IgniteInternalFuture future = awaitThread(() -> aware.markAsMovedToArchive(5)); + IgniteInternalFuture fut = awaitThread(() -> aware.markAsMovedToArchive(5)); //when: interrupt waiting. aware.interrupt(); //then: IgniteInterruptedCheckedException should be throw. - assertFalse(future.get(20) instanceof IgniteInterruptedCheckedException); + assertFalse(fut.get(20) instanceof IgniteInterruptedCheckedException); //and: last archived segment should be changed. assertEquals(5, aware.lastArchivedAbsoluteIndex()); @@ -435,13 +435,13 @@ public void testFinishWaitSegmentToCompress_WhenSetLastArchivedSegment() throws aware.onSegmentCompressed(5); - IgniteInternalFuture future = awaitThread(aware::waitNextSegmentToCompress); + IgniteInternalFuture fut = awaitThread(aware::waitNextSegmentToCompress); //when: archived expected segment. aware.setLastArchivedAbsoluteIndex(6); //then: waiting should finish immediately. - future.get(20); + fut.get(20); } /** @@ -454,13 +454,13 @@ public void testFinishWaitSegmentToCompress_WhenMarkLastArchivedSegment() throws aware.onSegmentCompressed(5); - IgniteInternalFuture future = awaitThread(aware::waitNextSegmentToCompress); + IgniteInternalFuture fut = awaitThread(aware::waitNextSegmentToCompress); //when: marked expected segment. aware.markAsMovedToArchive(6); //then: waiting should finish immediately. - future.get(20); + fut.get(20); } /** @@ -485,13 +485,13 @@ public void testFinishWaitSegmentToCompress_WhenInterruptWasCall() throws Ignite SegmentAware aware = segmentAware(10, true); aware.onSegmentCompressed(5); - IgniteInternalFuture future = awaitThread(aware::waitNextSegmentToCompress); + IgniteInternalFuture fut = awaitThread(aware::waitNextSegmentToCompress); //when: interrupt waiting. aware.interrupt(); //then: IgniteInterruptedCheckedException should be throw. - assertTrue(future.get(20) instanceof IgniteInterruptedCheckedException); + assertTrue(fut.get(20) instanceof IgniteInterruptedCheckedException); } /** @@ -1026,7 +1026,7 @@ private void assertFutureIsNotFinish(IgniteInternalFuture future) throws IgniteC */ private IgniteInternalFuture awaitThread(Waiter waiter) throws IgniteCheckedException, InterruptedException { CountDownLatch latch = new CountDownLatch(1); - IgniteInternalFuture future = runAsync( + IgniteInternalFuture fut = runAsync( () -> { latch.countDown(); try { @@ -1042,9 +1042,9 @@ private IgniteInternalFuture awaitThread(Waiter waiter) throws IgniteCheckedExce latch.await(); - assertFutureIsNotFinish(future); + assertFutureIsNotFinish(fut); - return future; + return fut; } /** diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/transactions/TxPartitionCounterStateAbstractTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/transactions/TxPartitionCounterStateAbstractTest.java index cb1aa54eb98dd..65ef7afee2c40 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/transactions/TxPartitionCounterStateAbstractTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/transactions/TxPartitionCounterStateAbstractTest.java @@ -928,8 +928,8 @@ private long countForNode(IgniteEx node, TxState state) { @Override public boolean onDone(@Nullable Object res, @Nullable Throwable err) { Collection> futures = futures(); - for (IgniteInternalFuture future : futures) - ((GridFutureAdapter)future).onDone(); + for (IgniteInternalFuture fut : futures) + ((GridFutureAdapter)fut).onDone(); return super.onDone(res, err); } diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/compute/IgniteComputeConfigVariationsFullApiTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/compute/IgniteComputeConfigVariationsFullApiTest.java index 85a6b904565de..8297d7519110b 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/compute/IgniteComputeConfigVariationsFullApiTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/compute/IgniteComputeConfigVariationsFullApiTest.java @@ -482,8 +482,8 @@ public void testApplyAsync() throws Exception { // Wait for results. Collection results = new ArrayList<>(MAX_JOB_COUNT); - for (IgniteFuture future : futures) - results.add(future.get()); + for (IgniteFuture fut : futures) + results.add(fut.get()); checkResultsClassCount(MAX_JOB_COUNT - 1, results, value(0).getClass()); assertCollectionsEquals("Results value mismatch", createGoldenResults(), results); @@ -656,8 +656,8 @@ public void testCallAsync() throws Exception { // Wait for results. Collection results = new ArrayList<>(MAX_JOB_COUNT); - for (IgniteFuture future : futures) - results.add(future.get()); + for (IgniteFuture fut : futures) + results.add(fut.get()); checkResultsClassCount(MAX_JOB_COUNT - 1, results, value(0).getClass()); assertCollectionsEquals("Results value mismatch", createGoldenResults(), results); diff --git a/modules/core/src/test/java/org/apache/ignite/internal/util/nio/FastSessionMoveAndKeyCancellationTest.java b/modules/core/src/test/java/org/apache/ignite/internal/util/nio/FastSessionMoveAndKeyCancellationTest.java index b03f2419d52f4..e261623312b79 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/util/nio/FastSessionMoveAndKeyCancellationTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/util/nio/FastSessionMoveAndKeyCancellationTest.java @@ -92,13 +92,13 @@ public void quickSessionMovingBetweenWorkersShouldNotTriggerCancelledKeyExceptio IgniteEx ignite = startGrid(1); IgniteClient client1 = startClient() ) { - IgniteInternalFuture clientJobsFuture = multithreadedAsync(new ReconnectConstantly(), 2); + IgniteInternalFuture clientJobsFut = multithreadedAsync(new ReconnectConstantly(), 2); try { assertFalse("CancelledKeyException was thrown", failureLogMessagesLatch.await(1, TimeUnit.MINUTES)); } finally { - clientJobsFuture.cancel(); + clientJobsFut.cancel(); } } } diff --git a/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoveryNodeJoinAndFailureTest.java b/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoveryNodeJoinAndFailureTest.java index a79b51411598d..0bdf0a0558a4e 100644 --- a/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoveryNodeJoinAndFailureTest.java +++ b/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoveryNodeJoinAndFailureTest.java @@ -134,7 +134,7 @@ Test reproduces the needed behavior (two nodes in CONNECTING state) doing the fo final AtomicInteger joinReqsCntr = new AtomicInteger(0); - final AtomicReference futureRef = new AtomicReference(); + final AtomicReference futRef = new AtomicReference(); final UUID node2Id = UUID.randomUUID(); @@ -179,7 +179,7 @@ Test reproduces the needed behavior (two nodes in CONNECTING state) doing the fo // No-op. } - futureRef.set(GridTestUtils.runAsync(() -> { + futRef.set(GridTestUtils.runAsync(() -> { try { startGrid(NODE_WITH_PORT_ID_3); } @@ -254,7 +254,7 @@ Test reproduces the needed behavior (two nodes in CONNECTING state) doing the fo assertTrue("Expected exception was not thrown.", expectedExThrown); - IgniteInternalFuture startGridFut = futureRef.get(); + IgniteInternalFuture startGridFut = futRef.get(); if (startGridFut != null) startGridFut.get(); diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/ClientReconnectWithSqlTableConfiguredTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/ClientReconnectWithSqlTableConfiguredTest.java index 42d8bda8d9352..88eee5e4f02db 100644 --- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/ClientReconnectWithSqlTableConfiguredTest.java +++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/ClientReconnectWithSqlTableConfiguredTest.java @@ -146,21 +146,21 @@ private void checkClientRecconect() throws Exception { AffinityTopologyVersion topVer = new AffinityTopologyVersion(3, 1); - AtomicReference lastFinishedFuture = new AtomicReference<>(); + AtomicReference lastFinishedFut = new AtomicReference<>(); assertTrue("Could not wait for autoactivation.", GridTestUtils.waitForCondition(() -> { for (GridDhtPartitionsExchangeFuture fut : client1.context().cache().context().exchange().exchangeFutures()) { if (fut.isDone() && fut.topologyVersion().equals(topVer)) { - lastFinishedFuture.set(fut); + lastFinishedFut.set(fut); return true; } } return false; }, 15_000)); - log.info(">>>>> lastFinishedFuture ver=" + lastFinishedFuture.get().topologyVersion()); + log.info(">>>>> lastFinishedFuture ver=" + lastFinishedFut.get().topologyVersion()); - Throwable t = U.field(lastFinishedFuture.get(), "exchangeLocE"); + Throwable t = U.field(lastFinishedFut.get(), "exchangeLocE"); assertNull("Unexpected exception on client node [exc=" + t + ']', t); } diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/IndexCorruptionRebuildTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/IndexCorruptionRebuildTest.java index 7e7baae256029..d762a32229a8e 100644 --- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/IndexCorruptionRebuildTest.java +++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/IndexCorruptionRebuildTest.java @@ -400,10 +400,10 @@ public IgniteInternalFuture rebuild( boolean force, IndexRebuildCancelToken cancelTok ) { - IgniteInternalFuture future = super.rebuild(cctx, force, cancelTok); - rebuiltIndexes = future != null; + IgniteInternalFuture fut = super.rebuild(cctx, force, cancelTok); + rebuiltIndexes = fut != null; - return future; + return fut; } /** diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/persistence/IgnitePdsIndexingDefragmentationTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/persistence/IgnitePdsIndexingDefragmentationTest.java index d90c87d834e67..3ed5c86798372 100644 --- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/persistence/IgnitePdsIndexingDefragmentationTest.java +++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/persistence/IgnitePdsIndexingDefragmentationTest.java @@ -380,10 +380,10 @@ public static class CaptureRebuildGridQueryIndexing extends IndexesRebuildTask { boolean force, IndexRebuildCancelToken cancelTok ) { - IgniteInternalFuture future = super.rebuild(cctx, force, cancelTok); - rebuiltIndexes = future != null; + IgniteInternalFuture fut = super.rebuild(cctx, force, cancelTok); + rebuiltIndexes = fut != null; - return future; + return fut; } /** diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/IgniteWalRecoveryTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/IgniteWalRecoveryTest.java index 6c654eca0b33e..115158326f093 100644 --- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/IgniteWalRecoveryTest.java +++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/IgniteWalRecoveryTest.java @@ -1355,7 +1355,7 @@ public void testAbsentDeadlock_Iterator_RollOver_Archivation() throws Exception } ); - IgniteInternalFuture future = GridTestUtils.runAsync( + IgniteInternalFuture fut = GridTestUtils.runAsync( () -> { for (int i = 0; i < 10000; i++) cache0.put(i, new IndexedObject(i)); @@ -1364,7 +1364,7 @@ public void testAbsentDeadlock_Iterator_RollOver_Archivation() throws Exception } ); - future.get(); + fut.get(); insertFinished.countDown(); diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/BusyExecutorTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/BusyExecutorTest.java index dc5e3e3326ae1..e4c25c7e8055a 100644 --- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/BusyExecutorTest.java +++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/BusyExecutorTest.java @@ -125,7 +125,7 @@ public void testActivateDeactivate() throws Exception { be.activate(); be.execute(taskExec); - CompletableFuture submitFuture = be.submit(taskSubmit); + CompletableFuture submitFut = be.submit(taskSubmit); be.execute(cancellableTask); Thread.sleep(TIME_TO_START_THREAD); diff --git a/modules/schedule/src/test/java/org/apache/ignite/internal/processors/schedule/GridScheduleSelfTest.java b/modules/schedule/src/test/java/org/apache/ignite/internal/processors/schedule/GridScheduleSelfTest.java index 39b43dd82e735..c59934ce36412 100644 --- a/modules/schedule/src/test/java/org/apache/ignite/internal/processors/schedule/GridScheduleSelfTest.java +++ b/modules/schedule/src/test/java/org/apache/ignite/internal/processors/schedule/GridScheduleSelfTest.java @@ -425,10 +425,10 @@ public void testNoNextExecutionTime() throws Exception { } }; - SchedulerFuture future = grid(0).scheduler().scheduleLocal(run, "{55} 53 3/5 * * *"); + SchedulerFuture fut = grid(0).scheduler().scheduleLocal(run, "{55} 53 3/5 * * *"); try { - future.get(); + fut.get(); fail("Accepted wrong cron expression"); } @@ -436,11 +436,11 @@ public void testNoNextExecutionTime() throws Exception { assertTrue(e.getMessage().startsWith("Invalid cron expression in schedule pattern")); } - assertTrue(future.isDone()); + assertTrue(fut.isDone()); - assertEquals(0, future.nextExecutionTime()); + assertEquals(0, fut.nextExecutionTime()); - assertEquals(0, future.nextExecutionTimes(2, System.currentTimeMillis()).length); + assertEquals(0, fut.nextExecutionTimes(2, System.currentTimeMillis()).length); } /**