mirror of https://github.com/apache/lucene.git
LUCENE-5810: fix MDW logic around fsync, now that NRTCachingDirectory extends FilterDirectory
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1610382 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
10ecbc5a97
commit
b9a05a7938
|
@ -192,6 +192,9 @@ public class MockDirectoryWrapper extends BaseDirectoryWrapper {
|
|||
private boolean mustSync() {
|
||||
Directory delegate = in;
|
||||
while (delegate instanceof FilterDirectory) {
|
||||
if (delegate instanceof NRTCachingDirectory) {
|
||||
return true;
|
||||
}
|
||||
delegate = ((FilterDirectory) delegate).getDelegate();
|
||||
}
|
||||
return delegate instanceof NRTCachingDirectory;
|
||||
|
|
Loading…
Reference in New Issue