Repository: incubator-ignite Updated Branches: refs/heads/ignite-709_3 06462598c -> ef6dd4119
# ignite-709_3 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/ef6dd411 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/ef6dd411 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/ef6dd411 Branch: refs/heads/ignite-709_3 Commit: ef6dd411994f2188217afe6e8d25fc8582e5a62e Parents: 0646259 Author: sboikov <[email protected]> Authored: Fri May 15 16:58:40 2015 +0300 Committer: sboikov <[email protected]> Committed: Fri May 15 16:58:40 2015 +0300 ---------------------------------------------------------------------- .../dht/preloader/GridDhtPartitionsExchangeFuture.java | 9 +++++++++ 1 file changed, 9 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/ef6dd411/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 d288c87..828e472 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 @@ -351,6 +351,15 @@ public class GridDhtPartitionsExchangeFuture extends GridFutureAdapter<AffinityT log.debug("Fetched affinity from remote node, initializing affinity assignment [locNodeId=" + cctx.localNodeId() + ", topVer=" + exchId.topologyVersion() + ']'); + if (affAssignment == null) { + affAssignment = new ArrayList<>(cacheCtx.affinity().partitions()); + + List<ClusterNode> empty = Collections.emptyList(); + + for (int i = 0; i < cacheCtx.affinity().partitions(); i++) + affAssignment.add(empty); + } + cacheCtx.affinity().initializeAffinity(exchId.topologyVersion(), affAssignment); } }
