Upgrade to Lucene 8.1.0 (#42214)

This commit upgrades to the GA release of Lucene 8.1.0
This commit is contained in:
Jim Ferenczi 2019-05-23 11:41:05 +02:00 committed by jimczi
parent 4ca5649a0d
commit b88e80ab89
53 changed files with 29 additions and 42 deletions

View File

@ -1,5 +1,5 @@
elasticsearch = 7.3.0
lucene = 8.1.0-snapshot-e460356abe
lucene = 8.1.0
bundled_jdk = 12.0.1+12@69cfe15208a647278a19ef0990eea691

View File

@ -1 +0,0 @@
0a1addebde14147501b7d24a581a7a7288bc585d

View File

@ -0,0 +1 @@
0c98e3b9d25f27ab05ac643cfb28756daa516bc7

View File

@ -1 +0,0 @@
b8b7d744e6294706b379ec7fdd2d6f1b6badc95b

View File

@ -0,0 +1 @@
d61364290eb1c28696e62b7df3a7d041d3be2fa5

View File

@ -1 +0,0 @@
c9dcc5568ccd4589f4a6871d2019661546106c83

View File

@ -0,0 +1 @@
7f78b18890a0a0e74a8249806a6cfcabd2fae304

View File

@ -1 +0,0 @@
bef6d901a9c8b4c6139de7419b3024e0c9fd4ad3

View File

@ -0,0 +1 @@
bfc6b5d67a792aa23ee134fe93307696aad94223

View File

@ -1 +0,0 @@
074c06d6f2254edae04acdd53bf6989a4343acc8

View File

@ -0,0 +1 @@
6fac1ff799b86f872b67e7fad55120d338daa86f

View File

@ -1 +0,0 @@
5cd2a341ab4524ec7ff40ba29faa4ead5e805413

View File

@ -0,0 +1 @@
72941af5e1bfb012aec04dd518a2deb43402702c

View File

@ -1 +0,0 @@
ba55aba7d278f6201b4ebd6dafbc7edb6fe94f8c

View File

@ -0,0 +1 @@
0ac885595cfdc0267d7d9cb843c22dabf7215ff0

View File

@ -1 +0,0 @@
543d99fd2ba4302f3555792236350b201514d821

View File

@ -0,0 +1 @@
e260cff7f48e350e1ec037dec1c260ce05ddb53e

View File

@ -1 +0,0 @@
c20a8ae0c3bd769aa6c415ebea94ba466d9a631d

View File

@ -0,0 +1 @@
262f20cb2786cdf7015a4ba1a64ce90ff2d746f5

View File

@ -1 +0,0 @@
6e8921ab37facdcc5c4b71f2612d72300d6de217

View File

@ -0,0 +1 @@
c5610306f8eff182b399b9aed7a60b82668a8395

View File

@ -1 +0,0 @@
3e85f77d8f8ed1db53dba387fbdec55a9f912639

View File

@ -0,0 +1 @@
46d614acdeb42f4661e91347100217bc72aae11e

View File

@ -1 +0,0 @@
426a1822d888a6341f6bafccaad19e4a2ad88e25

View File

@ -0,0 +1 @@
443f63d9038eea0601b493fa37fc599d74b035eb

View File

@ -1 +0,0 @@
f83fa4b264198dfb12436a803309a60f5588481d

View File

@ -0,0 +1 @@
e3e52591f8d44a4e1006ced4dd4a67f7a572990a

View File

@ -1 +0,0 @@
f381131abef51f77d26bccbb213d1c8563c19ec4

View File

@ -0,0 +1 @@
2e885b1e3e55f94ccc2744f85738563a577a4e21

View File

@ -1 +0,0 @@
8d8733551b9eb71e1f59688b8e78e0b481974d7a

View File

@ -0,0 +1 @@
e58d0092da1c4744627d57d022f4e07d8b80d11b

View File

@ -1 +0,0 @@
13da0b22f01dff4a01c9907425464a440695104b

View File

@ -0,0 +1 @@
07833aee2c5feb6fa1a16a21d27c8f15c01d0b4c

View File

@ -1 +0,0 @@
6c3de4dbb98b5cc00875d76e817929374bb9e710

View File

@ -0,0 +1 @@
63096d40298b8b8245a602d344b57bfa14b929fd

View File

@ -1 +0,0 @@
539ef199c74ae6891ac93f55632fe140b9d4c291

View File

@ -0,0 +1 @@
9bb4fb3c7035a877e4a87ed86870894509d26d65

View File

@ -1 +0,0 @@
0371141f658e2157babd490f0a8ddbcd5114b371

View File

@ -0,0 +1 @@
1033737c97703516134ba4c99d41724729854df4

View File

@ -1 +0,0 @@
1bae56fbce29d6c597c00889dab1909f51f4aaac

View File

@ -0,0 +1 @@
968d2fb35b0c2e68ac07c1ec187ab38a74b6602a

View File

@ -1 +0,0 @@
6eaed1dea9a18502ab9dffe55f081da6060373f7

View File

@ -0,0 +1 @@
551b7fa327645d3fd59ae1321320153b2f858766

View File

@ -1 +0,0 @@
e54c6be78275637544a3080874dd04b0d92755e5

View File

@ -0,0 +1 @@
45e63df708be458e95d9da3e6054189c50c30dff

View File

@ -1 +0,0 @@
e4c95d0bb740f18af520faebcebb968da3e0a687

View File

@ -0,0 +1 @@
d5cd0e619b473e132f03e3577d1b422f050f99c0

View File

@ -21,7 +21,6 @@ package org.elasticsearch.index.codec;
import org.apache.logging.log4j.Logger;
import org.apache.lucene.codecs.Codec;
import org.apache.lucene.codecs.lucene50.Lucene50PostingsFormat.FSTLoadMode;
import org.apache.lucene.codecs.lucene50.Lucene50StoredFieldsFormat.Mode;
import org.apache.lucene.codecs.lucene80.Lucene80Codec;
import org.elasticsearch.common.Nullable;
@ -49,7 +48,7 @@ public class CodecService {
final MapBuilder<String, Codec> codecs = MapBuilder.<String, Codec>newMapBuilder();
if (mapperService == null) {
codecs.put(DEFAULT_CODEC, new Lucene80Codec());
codecs.put(BEST_COMPRESSION_CODEC, new Lucene80Codec(Mode.BEST_COMPRESSION, FSTLoadMode.AUTO));
codecs.put(BEST_COMPRESSION_CODEC, new Lucene80Codec(Mode.BEST_COMPRESSION));
} else {
codecs.put(DEFAULT_CODEC,
new PerFieldMappingPostingFormatCodec(Mode.BEST_SPEED, mapperService, logger));

View File

@ -22,7 +22,6 @@ package org.elasticsearch.index.codec;
import org.apache.logging.log4j.Logger;
import org.apache.lucene.codecs.Codec;
import org.apache.lucene.codecs.PostingsFormat;
import org.apache.lucene.codecs.lucene50.Lucene50PostingsFormat.FSTLoadMode;
import org.apache.lucene.codecs.lucene50.Lucene50StoredFieldsFormat;
import org.apache.lucene.codecs.lucene80.Lucene80Codec;
import org.elasticsearch.common.lucene.Lucene;
@ -48,7 +47,7 @@ public class PerFieldMappingPostingFormatCodec extends Lucene80Codec {
}
public PerFieldMappingPostingFormatCodec(Lucene50StoredFieldsFormat.Mode compressionMode, MapperService mapperService, Logger logger) {
super(compressionMode, FSTLoadMode.AUTO);
super(compressionMode);
this.mapperService = mapperService;
this.logger = logger;
}

View File

@ -27,8 +27,6 @@ import org.apache.logging.log4j.Logger;
import org.apache.logging.log4j.core.LogEvent;
import org.apache.logging.log4j.core.appender.AbstractAppender;
import org.apache.logging.log4j.core.filter.RegexFilter;
import org.apache.lucene.codecs.lucene50.Lucene50PostingsFormat;
import org.apache.lucene.codecs.lucene50.Lucene50StoredFieldsFormat;
import org.apache.lucene.document.Field;
import org.apache.lucene.document.LongPoint;
import org.apache.lucene.document.NumericDocValuesField;
@ -132,7 +130,6 @@ import org.elasticsearch.indices.breaker.NoneCircuitBreakerService;
import org.elasticsearch.test.IndexSettingsModule;
import org.elasticsearch.test.VersionUtils;
import org.hamcrest.MatcherAssert;
import org.hamcrest.Matchers;
import java.io.Closeable;
import java.io.IOException;
@ -301,14 +298,6 @@ public class InternalEngineTests extends EngineTestCase {
assertThat(segments.get(0).getDeletedDocs(), equalTo(0));
assertThat(segments.get(0).isCompound(), equalTo(true));
assertThat(segments.get(0).ramTree, nullValue());
assertThat(segments.get(0).getAttributes().keySet(),
Matchers.contains(
// TODO: Lucene50PostingsFormat#MODE_KEY should be public ?
Lucene50PostingsFormat.class.getSimpleName() + ".fstMode",
Lucene50StoredFieldsFormat.MODE_KEY
)
);
engine.flush();
segments = engine.segments(false);

View File

@ -207,13 +207,13 @@ public class SimpleValidateQueryIT extends ESIntegTestCase {
// common terms queries
assertExplanation(QueryBuilders.commonTermsQuery("field", "huge brown pidgin").cutoffFrequency(1),
containsString("+field:pidgin (field:huge field:brown)"), true);
containsString("+field:pidgin field:huge field:brown"), true);
assertExplanation(QueryBuilders.commonTermsQuery("field", "the brown").analyzer("stop"),
containsString("field:brown"), true);
// match queries with cutoff frequency
assertExplanation(QueryBuilders.matchQuery("field", "huge brown pidgin").cutoffFrequency(1),
containsString("+field:pidgin (field:huge field:brown)"), true);
containsString("+field:pidgin field:huge field:brown"), true);
assertExplanation(QueryBuilders.matchQuery("field", "the brown").analyzer("stop"),
containsString("field:brown"), true);

View File

@ -1 +0,0 @@
3e85f77d8f8ed1db53dba387fbdec55a9f912639

View File

@ -0,0 +1 @@
46d614acdeb42f4661e91347100217bc72aae11e