mirror of https://github.com/apache/lucene.git
randomly commit in RIW.getReader even when pulling an NRT reader
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1152288 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
75e72c1fd9
commit
cc735b6e93
|
@ -354,6 +354,9 @@ public class RandomIndexWriter implements Closeable {
|
|||
if (LuceneTestCase.VERBOSE) {
|
||||
System.out.println("RIW.getReader: use NRT reader");
|
||||
}
|
||||
if (r.nextInt(5) == 1) {
|
||||
w.commit();
|
||||
}
|
||||
return w.getReader(applyDeletions);
|
||||
} else {
|
||||
if (LuceneTestCase.VERBOSE) {
|
||||
|
|
Loading…
Reference in New Issue