SOLR-5601: Use zkStateReader.getLeaderRetry to find the leader of a newly created temp collection

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1555083 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Shalin Shekhar Mangar 2014-01-03 13:39:11 +00:00
parent ca5f42a14e
commit 4612f80e8d
2 changed files with 2 additions and 2 deletions

View File

@ -83,7 +83,7 @@ Detailed Change List
New Features
----------------------
* SOLR-5308: A new 'migrate' collection API to split all documents with a
* SOLR-5308: SOLR-5601: A new 'migrate' collection API to split all documents with a
route key into another collection (shalin)
* SOLR-5441: Expose number of transaction log files and their size via JMX.

View File

@ -1191,7 +1191,7 @@ public class OverseerCollectionProcessor implements Runnable, ClosableThread {
// refresh cluster state
clusterState = zkStateReader.getClusterState();
Slice tempSourceSlice = clusterState.getCollection(tempSourceCollectionName).getSlices().iterator().next();
Replica tempSourceLeader = clusterState.getLeader(tempSourceCollectionName, tempSourceSlice.getName());
Replica tempSourceLeader = zkStateReader.getLeaderRetry(tempSourceCollectionName, tempSourceSlice.getName(), 60000);
String tempCollectionReplica1 = tempSourceCollectionName + "_" + tempSourceSlice.getName() + "_replica1";
String coreNodeName = waitForCoreNodeName(clusterState.getCollection(tempSourceCollectionName),