lucene-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From markrmil...@apache.org
Subject svn commit: r1458123 - in /lucene/dev/branches/lucene_solr_4_2: ./ solr/ solr/CHANGES.txt solr/core/ solr/core/src/java/org/apache/solr/update/DefaultSolrCoreState.java
Date Tue, 19 Mar 2013 04:17:05 GMT
Author: markrmiller
Date: Tue Mar 19 04:17:05 2013
New Revision: 1458123

URL: http://svn.apache.org/r1458123
Log:
SOLR-4592: DefaultSolrCoreState#doRecovery needs to check the CoreContainer shutdown flag
inside the recoveryLock sync block.

Modified:
    lucene/dev/branches/lucene_solr_4_2/   (props changed)
    lucene/dev/branches/lucene_solr_4_2/solr/   (props changed)
    lucene/dev/branches/lucene_solr_4_2/solr/CHANGES.txt   (contents, props changed)
    lucene/dev/branches/lucene_solr_4_2/solr/core/   (props changed)
    lucene/dev/branches/lucene_solr_4_2/solr/core/src/java/org/apache/solr/update/DefaultSolrCoreState.java

Modified: lucene/dev/branches/lucene_solr_4_2/solr/CHANGES.txt
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene_solr_4_2/solr/CHANGES.txt?rev=1458123&r1=1458122&r2=1458123&view=diff
==============================================================================
--- lucene/dev/branches/lucene_solr_4_2/solr/CHANGES.txt (original)
+++ lucene/dev/branches/lucene_solr_4_2/solr/CHANGES.txt Tue Mar 19 04:17:05 2013
@@ -73,6 +73,9 @@ Bug Fixes
 * SOLR-4585: The Collections API validates numShards with < 0 but should use 
   <= 0. (Mark Miller)
 
+* SOLR-4592: DefaultSolrCoreState#doRecovery needs to check the CoreContainer
+  shutdown flag inside the recoveryLock sync block. (Mark Miller)
+
 Optimizations
 ----------------------
 

Modified: lucene/dev/branches/lucene_solr_4_2/solr/core/src/java/org/apache/solr/update/DefaultSolrCoreState.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene_solr_4_2/solr/core/src/java/org/apache/solr/update/DefaultSolrCoreState.java?rev=1458123&r1=1458122&r2=1458123&view=diff
==============================================================================
--- lucene/dev/branches/lucene_solr_4_2/solr/core/src/java/org/apache/solr/update/DefaultSolrCoreState.java
(original)
+++ lucene/dev/branches/lucene_solr_4_2/solr/core/src/java/org/apache/solr/update/DefaultSolrCoreState.java
Tue Mar 19 04:17:05 2013
@@ -207,12 +207,18 @@ public final class DefaultSolrCoreState 
       return;
     }
     
+    // check before we grab the lock
     if (cc.isShutDown()) {
       log.warn("Skipping recovery because Solr is shutdown");
       return;
     }
     
     synchronized (recoveryLock) {
+      // to be air tight we must also check after lock
+      if (cc.isShutDown()) {
+        log.warn("Skipping recovery because Solr is shutdown");
+        return;
+      }
       log.info("Running recovery - first canceling any ongoing recovery");
       cancelRecovery();
       



Mime
View raw message