mirror of https://github.com/apache/lucene.git
commit changes after doRandomForceMerge, or otherwise they're lost
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1607778 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
006bee46c8
commit
f878737c44
|
@ -364,6 +364,8 @@ public class RandomIndexWriter implements Closeable {
|
|||
// forceMerge since presumably they might open a reader on the dir.
|
||||
if (getReaderCalled == false && r.nextInt(8) == 2) {
|
||||
doRandomForceMerge();
|
||||
// index may have changed, must commit the changes, or otherwise they are discarded by the call to close()
|
||||
w.commit();
|
||||
}
|
||||
w.close();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue