| Index: CHANGES.txt |
| =================================================================== |
| --- CHANGES.txt (revision 826548) |
| +++ CHANGES.txt (working copy) |
| @@ -107,6 +107,9 @@ |
| * LUCENE-1986: Fix NPE when scoring PayloadNearQuery (Peter Keegan, |
| Mark Miller via Mike McCandless) |
| |
| +* LUCENE-1992: Fix thread hazard if a merge is committing just as an |
| + exception occurs during sync (Uwe Schindler, Mike McCandless) |
| + |
| New features |
| |
| * LUCENE-1933: Provide a convenience AttributeFactory that creates a |
| Index: src/test/org/apache/lucene/index/TestIndexWriter.java |
| =================================================================== |
| --- src/test/org/apache/lucene/index/TestIndexWriter.java (revision 826548) |
| +++ src/test/org/apache/lucene/index/TestIndexWriter.java (working copy) |
| @@ -2698,8 +2698,6 @@ |
| failure.setDoFail(); |
| |
| ConcurrentMergeScheduler cms = new ConcurrentMergeScheduler(); |
| - // We expect sync exceptions in the merge threads |
| - cms.setSuppressExceptions(); |
| writer.setMergeScheduler(cms); |
| writer.setMaxBufferedDocs(2); |
| writer.setMergeFactor(5); |
| Index: src/java/org/apache/lucene/index/IndexWriter.java |
| =================================================================== |
| --- src/java/org/apache/lucene/index/IndexWriter.java (revision 826548) |
| +++ src/java/org/apache/lucene/index/IndexWriter.java (working copy) |
| @@ -3812,7 +3812,7 @@ |
| |
| // Must note the change to segmentInfos so any commits |
| // in-flight don't lose it: |
| - changeCount++; |
| + checkpoint(); |
| |
| // If the merged segments had pending changes, clear |
| // them so that they don't bother writing them to |