jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mreut...@apache.org
Subject svn commit: r532351 - /jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/query/lucene/MultiIndex.java
Date Wed, 25 Apr 2007 13:42:03 GMT
Author: mreutegg
Date: Wed Apr 25 06:42:02 2007
New Revision: 532351

URL: http://svn.apache.org/viewvc?view=rev&rev=532351
Log:
JCR-886: Index recovery may fail with IllegalArgumentException

Modified:
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/query/lucene/MultiIndex.java

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/query/lucene/MultiIndex.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/query/lucene/MultiIndex.java?view=diff&rev=532351&r1=532350&r2=532351
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/query/lucene/MultiIndex.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/query/lucene/MultiIndex.java
Wed Apr 25 06:42:02 2007
@@ -781,7 +781,11 @@
         // remove it from the lists if index is registered
         indexes.remove(index);
         indexNames.removeName(index.getName());
-        deletable.addName(index.getName());
+        // during recovery it may happen that an index had already been marked
+        // deleted, so we need to check if it is already marked deleted.
+        if (!deletable.contains(index.getName())) {
+            deletable.addName(index.getName());
+        }
     }
 
     /**



Mime
View raw message