LUCENE-8149: NRTCachingDirectory does not need to preemptively delete segment files and generate exceptions

This commit is contained in:
Erick Erickson 2018-02-05 11:08:13 -08:00
parent dd90bfbe87
commit 4bd49726c1
2 changed files with 3 additions and 10 deletions

View File

@ -142,18 +142,8 @@ public class NRTCachingDirectory extends FilterDirectory implements Accountable
if (VERBOSE) {
System.out.println(" to cache");
}
try {
in.deleteFile(name);
} catch (IOException ioe) {
// This is fine: file may not exist
}
return cache.createOutput(name, context);
} else {
try {
cache.deleteFile(name);
} catch (IOException ioe) {
// This is fine: file may not exist
}
return in.createOutput(name, context);
}
}

View File

@ -192,6 +192,9 @@ Optimizations
* SOLR-11711: Fixed distributed processing of facet.field/facet.pivot sub requests to prevent requesting
unneccessary and excessive '0' count terms from each shard (Houston Putman via hossman)
* LUCENE-8149: NRTCachingDirectory does not need to preemptively delete segment files and generate exceptions
(Erick Erickson)
Other Changes
----------------------