From f6afc01fe5ba54acc33b229da19f56b0c73629ba Mon Sep 17 00:00:00 2001 From: kimchy Date: Thu, 23 Dec 2010 17:26:32 +0200 Subject: [PATCH] add reconnection code between nodes that are not masters --- .../service/InternalClusterService.java | 35 +++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/modules/elasticsearch/src/main/java/org/elasticsearch/cluster/service/InternalClusterService.java b/modules/elasticsearch/src/main/java/org/elasticsearch/cluster/service/InternalClusterService.java index d30dc5ced1b..3d5cdee078f 100644 --- a/modules/elasticsearch/src/main/java/org/elasticsearch/cluster/service/InternalClusterService.java +++ b/modules/elasticsearch/src/main/java/org/elasticsearch/cluster/service/InternalClusterService.java @@ -42,6 +42,7 @@ import java.util.List; import java.util.Queue; import java.util.concurrent.CopyOnWriteArrayList; import java.util.concurrent.ExecutorService; +import java.util.concurrent.ScheduledFuture; import java.util.concurrent.TimeUnit; import static java.util.concurrent.Executors.*; @@ -63,6 +64,8 @@ public class InternalClusterService extends AbstractLifecycleComponent clusterStateListeners = new CopyOnWriteArrayList(); @@ -71,6 +74,8 @@ public class InternalClusterService extends AbstractLifecycleComponent onGoingTimeout : onGoingTimeouts) { onGoingTimeout.v1().cancel(); onGoingTimeout.v2().listener.onClose(); @@ -262,4 +271,30 @@ public class InternalClusterService extends AbstractLifecycleComponent