You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by sh...@apache.org on 2015/01/22 01:10:55 UTC
svn commit: r1653716 - in /lucene/dev/trunk/solr: CHANGES.txt
core/src/java/org/apache/solr/cloud/OverseerCollectionProcessor.java
Author: shalin
Date: Thu Jan 22 00:10:55 2015
New Revision: 1653716
URL: http://svn.apache.org/r1653716
Log:
SOLR-7011: Delete collection returns before collection is actually removed
Modified:
lucene/dev/trunk/solr/CHANGES.txt
lucene/dev/trunk/solr/core/src/java/org/apache/solr/cloud/OverseerCollectionProcessor.java
Modified: lucene/dev/trunk/solr/CHANGES.txt
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/solr/CHANGES.txt?rev=1653716&r1=1653715&r2=1653716&view=diff
==============================================================================
--- lucene/dev/trunk/solr/CHANGES.txt (original)
+++ lucene/dev/trunk/solr/CHANGES.txt Thu Jan 22 00:10:55 2015
@@ -521,6 +521,9 @@ Bug Fixes
* SOLR-6928: solr.cmd stop works only in english (john.work, Jan Høydahl, Timothy Potter)
+* SOLR-7011: Delete collection returns before collection is actually removed.
+ (Christine Poerschke via shalin)
+
Optimizations
----------------------
Modified: lucene/dev/trunk/solr/core/src/java/org/apache/solr/cloud/OverseerCollectionProcessor.java
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/solr/core/src/java/org/apache/solr/cloud/OverseerCollectionProcessor.java?rev=1653716&r1=1653715&r2=1653716&view=diff
==============================================================================
--- lucene/dev/trunk/solr/core/src/java/org/apache/solr/cloud/OverseerCollectionProcessor.java (original)
+++ lucene/dev/trunk/solr/core/src/java/org/apache/solr/cloud/OverseerCollectionProcessor.java Thu Jan 22 00:10:55 2015
@@ -1161,7 +1161,7 @@ public class OverseerCollectionProcessor
private void deleteCollection(ZkNodeProps message, NamedList results)
throws KeeperException, InterruptedException {
- String collection = message.getStr("name");
+ final String collection = message.getStr("name");
try {
ModifiableSolrParams params = new ModifiableSolrParams();
params.set(CoreAdminParams.ACTION, CoreAdminAction.UNLOAD.toString());
@@ -1181,7 +1181,7 @@ public class OverseerCollectionProcessor
boolean removed = false;
while (System.nanoTime() < timeout) {
Thread.sleep(100);
- removed = !zkStateReader.getClusterState().hasCollection(message.getStr(collection));
+ removed = !zkStateReader.getClusterState().hasCollection(collection);
if (removed) {
Thread.sleep(500); // just a bit of time so it's more likely other
// readers see on return
@@ -1190,7 +1190,7 @@ public class OverseerCollectionProcessor
}
if (!removed) {
throw new SolrException(ErrorCode.SERVER_ERROR,
- "Could not fully remove collection: " + message.getStr("name"));
+ "Could not fully remove collection: " + collection);
}
} finally {