You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by ma...@apache.org on 2011/12/27 21:14:40 UTC
svn commit: r1224999 -
/lucene/dev/branches/solrcloud/solr/core/src/java/org/apache/solr/update/FSUpdateLog.java
Author: markrmiller
Date: Tue Dec 27 20:14:39 2011
New Revision: 1224999
URL: http://svn.apache.org/viewvc?rev=1224999&view=rev
Log:
make bufferUpdates work the same as applyBufferedUpdates
Modified:
lucene/dev/branches/solrcloud/solr/core/src/java/org/apache/solr/update/FSUpdateLog.java
Modified: lucene/dev/branches/solrcloud/solr/core/src/java/org/apache/solr/update/FSUpdateLog.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/solrcloud/solr/core/src/java/org/apache/solr/update/FSUpdateLog.java?rev=1224999&r1=1224998&r2=1224999&view=diff
==============================================================================
--- lucene/dev/branches/solrcloud/solr/core/src/java/org/apache/solr/update/FSUpdateLog.java (original)
+++ lucene/dev/branches/solrcloud/solr/core/src/java/org/apache/solr/update/FSUpdateLog.java Tue Dec 27 20:14:39 2011
@@ -565,13 +565,18 @@ public class FSUpdateLog extends UpdateL
@Override
public void bufferUpdates() {
- assert state == State.ACTIVE;
+ // recovery trips this assert under some race - even when
+ // it checks the state first
+ // assert state == State.ACTIVE;
+
recoveryInfo = new RecoveryInfo();
// block all updates to eliminate race conditions
// reading state and acting on it in the update processor
versionInfo.blockUpdates();
try {
+ if (state != State.ACTIVE) return;
+
if (log.isInfoEnabled()) {
log.info("Starting to buffer updates. " + this);
}