You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by sb...@apache.org on 2017/07/04 14:14:06 UTC
[2/8] ignite git commit: Remove some unused parameters.
Remove some unused parameters.
Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/3cc13eae
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/3cc13eae
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/3cc13eae
Branch: refs/heads/ignite-gg-12389
Commit: 3cc13eae99b2f4f86a9c679efd31a4e87a37d4fd
Parents: bdd31af
Author: sboikov <sb...@gridgain.com>
Authored: Mon Jul 3 16:03:37 2017 +0300
Committer: sboikov <sb...@gridgain.com>
Committed: Mon Jul 3 16:03:37 2017 +0300
----------------------------------------------------------------------
.../cache/GridCachePartitionExchangeManager.java | 15 ++++++---------
.../preloader/GridDhtPartitionsExchangeFuture.java | 11 ++++-------
2 files changed, 10 insertions(+), 16 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ignite/blob/3cc13eae/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCachePartitionExchangeManager.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCachePartitionExchangeManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCachePartitionExchangeManager.java
index cbb07f9..2d1aca0 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCachePartitionExchangeManager.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCachePartitionExchangeManager.java
@@ -860,7 +860,7 @@ public class GridCachePartitionExchangeManager<K, V> extends GridCacheSharedMana
* @param nodes Nodes.
*/
private void sendAllPartitions(Collection<ClusterNode> nodes) {
- GridDhtPartitionsFullMessage m = createPartitionsFullMessage(nodes, null, null, true);
+ GridDhtPartitionsFullMessage m = createPartitionsFullMessage(null, null);
if (log.isDebugEnabled())
log.debug("Sending all partitions [nodeIds=" + U.nodeIds(nodes) + ", msg=" + m + ']');
@@ -883,21 +883,18 @@ public class GridCachePartitionExchangeManager<K, V> extends GridCacheSharedMana
}
/**
- * @param nodes Target nodes.
* @param exchId Non-null exchange ID if message is created for exchange.
* @param lastVer Last version.
- * @param compress {@code True} if it is possible to use compression for message.
* @return Message.
*/
- public GridDhtPartitionsFullMessage createPartitionsFullMessage(Collection<ClusterNode> nodes,
+ public GridDhtPartitionsFullMessage createPartitionsFullMessage(
final @Nullable GridDhtPartitionExchangeId exchId,
- @Nullable GridCacheVersion lastVer,
- final boolean compress) {
+ @Nullable GridCacheVersion lastVer) {
final GridDhtPartitionsFullMessage m = new GridDhtPartitionsFullMessage(exchId,
lastVer,
exchId != null ? exchId.topologyVersion() : AffinityTopologyVersion.NONE);
- m.compress(compress);
+ m.compress(true);
final Map<Object, T2<Integer, GridDhtPartitionFullMap>> dupData = new HashMap<>();
@@ -917,7 +914,7 @@ public class GridCachePartitionExchangeManager<K, V> extends GridCacheSharedMana
if (locMap != null) {
addFullPartitionsMap(m,
dupData,
- compress,
+ true,
grp.groupId(),
locMap,
affCache.similarAffinityKey());
@@ -935,7 +932,7 @@ public class GridCachePartitionExchangeManager<K, V> extends GridCacheSharedMana
if (map != null) {
addFullPartitionsMap(m,
dupData,
- compress,
+ true,
top.groupId(),
map,
top.similarAffinityKey());
http://git-wip-us.apache.org/repos/asf/ignite/blob/3cc13eae/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 3dc2242..7471855 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
@@ -1083,17 +1083,14 @@ public class GridDhtPartitionsExchangeFuture extends GridDhtTopologyFutureAdapte
}
/**
- * @param compress {@code True} if it is possible to use compression for message.
* @return Message.
*/
- private GridDhtPartitionsFullMessage createPartitionsMessage(Collection<ClusterNode> nodes, boolean compress) {
+ private GridDhtPartitionsFullMessage createPartitionsMessage() {
GridCacheVersion last = lastVer.get();
GridDhtPartitionsFullMessage m = cctx.exchange().createPartitionsFullMessage(
- nodes,
exchangeId(),
- last != null ? last : cctx.versions().last(),
- compress);
+ last != null ? last : cctx.versions().last());
if (exchangeOnChangeGlobalState && !F.isEmpty(changeGlobalStateExceptions))
m.setExceptionsMap(changeGlobalStateExceptions);
@@ -1106,7 +1103,7 @@ public class GridDhtPartitionsExchangeFuture extends GridDhtTopologyFutureAdapte
* @throws IgniteCheckedException If failed.
*/
private void sendAllPartitions(Collection<ClusterNode> nodes) throws IgniteCheckedException {
- GridDhtPartitionsFullMessage m = createPartitionsMessage(nodes, true);
+ GridDhtPartitionsFullMessage m = createPartitionsMessage();
assert !nodes.contains(cctx.localNode());
@@ -1390,7 +1387,7 @@ public class GridDhtPartitionsExchangeFuture extends GridDhtTopologyFutureAdapte
Map<Integer, Map<Integer, List<UUID>>> assignmentChange = fut.get();
- GridDhtPartitionsFullMessage m = createPartitionsMessage(null, false);
+ GridDhtPartitionsFullMessage m = createPartitionsMessage();
CacheAffinityChangeMessage msg = new CacheAffinityChangeMessage(exchId, m, assignmentChange);