You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by dg...@apache.org on 2018/09/14 21:26:39 UTC
ignite git commit: IGNITE-7618 Fix synchronously wait for dchange
cluster state in validate cache operation - Fixes #4733.
Repository: ignite
Updated Branches:
refs/heads/master ad2f58ec7 -> b263dc150
IGNITE-7618 Fix synchronously wait for dchange cluster state in validate cache operation - Fixes #4733.
Signed-off-by: Dmitriy Govorukhin <dm...@gmail.com>
Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/b263dc15
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/b263dc15
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/b263dc15
Branch: refs/heads/master
Commit: b263dc150ff49c58b525644361dbd21bdc2c9639
Parents: ad2f58e
Author: ibessonov <be...@gmail.com>
Authored: Sat Sep 15 00:25:39 2018 +0300
Committer: Dmitriy Govorukhin <dm...@gmail.com>
Committed: Sat Sep 15 00:25:39 2018 +0300
----------------------------------------------------------------------
.../cache/distributed/dht/GridDhtTopologyFutureAdapter.java | 5 ++++-
.../dht/preloader/GridDhtPartitionsExchangeFuture.java | 2 ++
2 files changed, 6 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ignite/blob/b263dc15/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTopologyFutureAdapter.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTopologyFutureAdapter.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTopologyFutureAdapter.java
index 3c3150a..539fef4 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTopologyFutureAdapter.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTopologyFutureAdapter.java
@@ -44,6 +44,9 @@ public abstract class GridDhtTopologyFutureAdapter extends GridFutureAdapter<Aff
/** Cache groups validation results. */
protected volatile Map<Integer, CacheValidation> grpValidRes;
+ /** Whether or not cluster is active. */
+ protected volatile boolean clusterIsActive = true;
+
/**
* @param grp Cache group.
* @param topNodes Topology nodes.
@@ -80,7 +83,7 @@ public abstract class GridDhtTopologyFutureAdapter extends GridFutureAdapter<Aff
if (err != null)
return err;
- if (!cctx.shared().kernalContext().state().publicApiActiveState(true))
+ if (!clusterIsActive)
return new CacheInvalidStateException(
"Failed to perform cache operation (cluster is not activated): " + cctx.name());
http://git-wip-us.apache.org/repos/asf/ignite/blob/b263dc15/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionsExchangeFuture.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionsExchangeFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionsExchangeFuture.java
index e66511c..265c48d 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionsExchangeFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionsExchangeFuture.java
@@ -345,6 +345,8 @@ public class GridDhtPartitionsExchangeFuture extends GridDhtTopologyFutureAdapte
this.exchActions = exchActions;
this.affChangeMsg = affChangeMsg;
this.validator = new GridDhtPartitionsStateValidator(cctx);
+ if (exchActions != null && exchActions.deactivate())
+ this.clusterIsActive = false;
log = cctx.logger(getClass());
exchLog = cctx.logger(EXCHANGE_LOG);