ignite-6124 DataStreamerImpl: do not wait for exchange future inside cache gateway.
@@ -764,13 +764,6 @@ public class DataStreamerImpl<K, V> implements IgniteDataStreamer<K, V>, Delayed
GridCacheGateway gate = null;
- if (!allowOverwrite() && !cctx.isLocal()) { // Cases where cctx required.
- gate = cctx.gate();
-
- gate.enter();
- }
-
- try {
AffinityTopologyVersion topVer;
if (!cctx.isLocal())
@@ -778,6 +771,13 @@ public class DataStreamerImpl<K, V> implements IgniteDataStreamer<K, V>, Delayed
else
topVer = ctx.cache().context().exchange().readyAffinityVersion();
+ if (!allowOverwrite() && !cctx.isLocal()) { // Cases where cctx required.
+ gate = cctx.gate();
+
+ gate.enter();
+ }
+
+ try {
for (DataStreamerEntry entry : entries) {
List<ClusterNode> nodes;
