Fix compilation

This commit is contained in:
Simon Willnauer 2015-01-29 17:41:53 +01:00
parent 03f1fcc85e
commit 1d77c3af82
1 changed files with 4 additions and 4 deletions

View File

@ -1582,7 +1582,7 @@ public class InternalEngineTests extends ElasticsearchLuceneTestCase {
index = new Engine.Create(null, analyzer, newUid("1"), doc, Versions.MATCH_ANY, VersionType.INTERNAL, PRIMARY, System.nanoTime(), canHaveDuplicates, autoGeneratedId); index = new Engine.Create(null, analyzer, newUid("1"), doc, Versions.MATCH_ANY, VersionType.INTERNAL, PRIMARY, System.nanoTime(), canHaveDuplicates, autoGeneratedId);
engine.create(index); engine.create(index);
assertThat(index.version(), equalTo(1l)); assertThat(index.version(), equalTo(1l));
engine.refresh("test", true); engine.refresh("test");
Engine.Searcher searcher = engine.acquireSearcher("test"); Engine.Searcher searcher = engine.acquireSearcher("test");
TopDocs topDocs = searcher.searcher().search(new MatchAllDocsQuery(), 10); TopDocs topDocs = searcher.searcher().search(new MatchAllDocsQuery(), 10);
assertThat(topDocs.totalHits, equalTo(1)); assertThat(topDocs.totalHits, equalTo(1));
@ -1594,7 +1594,7 @@ public class InternalEngineTests extends ElasticsearchLuceneTestCase {
} catch (VersionConflictEngineException e) { } catch (VersionConflictEngineException e) {
// we ignore version conflicts on replicas, see TransportShardReplicationOperationAction.ignoreReplicaException // we ignore version conflicts on replicas, see TransportShardReplicationOperationAction.ignoreReplicaException
} }
replicaEngine.refresh("test", true); replicaEngine.refresh("test");
Engine.Searcher replicaSearcher = replicaEngine.acquireSearcher("test"); Engine.Searcher replicaSearcher = replicaEngine.acquireSearcher("test");
topDocs = replicaSearcher.searcher().search(new MatchAllDocsQuery(), 10); topDocs = replicaSearcher.searcher().search(new MatchAllDocsQuery(), 10);
assertThat(topDocs.totalHits, equalTo(1)); assertThat(topDocs.totalHits, equalTo(1));
@ -1626,7 +1626,7 @@ public class InternalEngineTests extends ElasticsearchLuceneTestCase {
// we can ignore the exception. In case this happens because the retry request arrived first then this error will not be sent back anyway. // we can ignore the exception. In case this happens because the retry request arrived first then this error will not be sent back anyway.
// in any other case this is an actual error // in any other case this is an actual error
} }
engine.refresh("test", true); engine.refresh("test");
Engine.Searcher searcher = engine.acquireSearcher("test"); Engine.Searcher searcher = engine.acquireSearcher("test");
TopDocs topDocs = searcher.searcher().search(new MatchAllDocsQuery(), 10); TopDocs topDocs = searcher.searcher().search(new MatchAllDocsQuery(), 10);
assertThat(topDocs.totalHits, equalTo(1)); assertThat(topDocs.totalHits, equalTo(1));
@ -1638,7 +1638,7 @@ public class InternalEngineTests extends ElasticsearchLuceneTestCase {
} catch (VersionConflictEngineException e) { } catch (VersionConflictEngineException e) {
// we ignore version conflicts on replicas, see TransportShardReplicationOperationAction.ignoreReplicaException. // we ignore version conflicts on replicas, see TransportShardReplicationOperationAction.ignoreReplicaException.
} }
replicaEngine.refresh("test", true); replicaEngine.refresh("test");
Engine.Searcher replicaSearcher = replicaEngine.acquireSearcher("test"); Engine.Searcher replicaSearcher = replicaEngine.acquireSearcher("test");
topDocs = replicaSearcher.searcher().search(new MatchAllDocsQuery(), 10); topDocs = replicaSearcher.searcher().search(new MatchAllDocsQuery(), 10);
assertThat(topDocs.totalHits, equalTo(1)); assertThat(topDocs.totalHits, equalTo(1));