Skip to content

Commit

Permalink
Merge pull request #203 from expani/issue-11415-3
Browse files Browse the repository at this point in the history
Fixed unit tests for lucene 10 upgrade
  • Loading branch information
reta authored Dec 21, 2024
2 parents 3549c2d + 60b781b commit 5871134
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ public ScoreCachingLeafBucketCollector(LeafBucketCollector in) {
@Override
public void setScorer(Scorable scorer) throws IOException {
scoreCachingWrappingScorer = new ScoreCachingWrappingScorer(scorer);
super.setScorer(scoreCachingWrappingScorer);
in.setScorer(scoreCachingWrappingScorer);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
import org.apache.lucene.index.IndexWriterConfig;
import org.apache.lucene.search.Query;
import org.apache.lucene.search.QueryCachingPolicy;
import org.apache.lucene.search.suggest.document.Completion912PostingsFormat;
import org.apache.lucene.search.suggest.document.Completion101PostingsFormat;
import org.apache.lucene.search.suggest.document.SuggestField;
import org.apache.lucene.store.Directory;
import org.opensearch.OpenSearchException;
Expand Down Expand Up @@ -69,7 +69,7 @@ public void testExceptionsAreNotCached() {

public void testCompletionStatsCache() throws IOException, InterruptedException {
final IndexWriterConfig indexWriterConfig = newIndexWriterConfig();
final PostingsFormat postingsFormat = new Completion912PostingsFormat();
final PostingsFormat postingsFormat = new Completion101PostingsFormat();
indexWriterConfig.setCodec(new Lucene101Codec() {
@Override
public PostingsFormat getPostingsFormatForField(String field) {
Expand Down

0 comments on commit 5871134

Please sign in to comment.