fix javadocs: maybeReopen -> maybeRefresh

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1646764 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Michael McCandless 2014-12-19 15:07:25 +00:00
parent e4180d30bb
commit 8908328de4
2 changed files with 4 additions and 4 deletions

View File

@ -47,8 +47,8 @@ import org.apache.lucene.store.Directory;
* <p> * <p>
* In addition you should periodically call {@link #maybeRefresh}. While it's * In addition you should periodically call {@link #maybeRefresh}. While it's
* possible to call this just before running each query, this is discouraged * possible to call this just before running each query, this is discouraged
* since it penalizes the unlucky queries that do the reopen. It's better to use * since it penalizes the unlucky queries that need to refresh. It's better to use
* a separate background thread, that periodically calls maybeReopen. Finally, * a separate background thread, that periodically calls {@link #maybeRefresh}. Finally,
* be sure to call {@link #close} once you are done. * be sure to call {@link #close} once you are done.
* *
* @see SearcherFactory * @see SearcherFactory

View File

@ -146,7 +146,7 @@ public class TestSearcherManager extends ThreadedIndexingAndSearchingTestCase {
@Override @Override
protected IndexSearcher getCurrentSearcher() throws Exception { protected IndexSearcher getCurrentSearcher() throws Exception {
if (random().nextInt(10) == 7) { if (random().nextInt(10) == 7) {
// NOTE: not best practice to call maybeReopen // NOTE: not best practice to call maybeRefresh
// synchronous to your search threads, but still we // synchronous to your search threads, but still we
// test as apps will presumably do this for // test as apps will presumably do this for
// simplicity: // simplicity:
@ -251,7 +251,7 @@ public class TestSearcherManager extends ThreadedIndexingAndSearchingTestCase {
try { try {
triedReopen.set(true); triedReopen.set(true);
if (VERBOSE) { if (VERBOSE) {
System.out.println("NOW call maybeReopen"); System.out.println("NOW call maybeRefresh");
} }
searcherManager.maybeRefresh(); searcherManager.maybeRefresh();
success.set(true); success.set(true);