From 83debcaef07c99f2794aff31f9261f785a32d20b Mon Sep 17 00:00:00 2001 From: Shalin Shekhar Mangar Date: Tue, 11 Feb 2014 11:11:55 +0000 Subject: [PATCH] SOLR-5689: On reconnect, ZkController cancels election on first context rather than latest git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1567049 13f79535-47bb-0310-9956-ffa450edef68 --- solr/CHANGES.txt | 3 +++ solr/core/src/java/org/apache/solr/cloud/ZkController.java | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/solr/CHANGES.txt b/solr/CHANGES.txt index cb820429e01..00712470eed 100644 --- a/solr/CHANGES.txt +++ b/solr/CHANGES.txt @@ -316,6 +316,9 @@ Bug Fixes to properly specify discountOverlap option. (Isaac Hebsh, Ahmet Arslan, Vitaliy Zhovtyuk, hossman) +* SOLR-5689: On reconnect, ZkController cancels election on first context rather + than latest. (Gregory Chanan, Mark Miller via shalin) + Optimizations ---------------------- diff --git a/solr/core/src/java/org/apache/solr/cloud/ZkController.java b/solr/core/src/java/org/apache/solr/cloud/ZkController.java index 41ca765abb6..2eea40dc41d 100644 --- a/solr/core/src/java/org/apache/solr/cloud/ZkController.java +++ b/solr/core/src/java/org/apache/solr/cloud/ZkController.java @@ -222,7 +222,8 @@ public final class ZkController { if (prevContext != null) { prevContext.cancelElection(); } - + + overseerElector.setup(context); overseerElector.joinElection(context, true); zkStateReader.createClusterStateWatchersAndUpdate();