[Rename] Fix import issues in tests. (#414)
This commit fixes the import issues in already refactored test packages. Signed-off-by: Rabi Panda <adnapibar@gmail.com>
This commit is contained in:
parent
b97834ce99
commit
d1e070c92b
|
@ -411,7 +411,7 @@ public class CommonAnalysisPlugin extends Plugin implements AnalysisPlugin, Scri
|
|||
public List<PreConfiguredCharFilter> getPreConfiguredCharFilters() {
|
||||
List<PreConfiguredCharFilter> filters = new ArrayList<>();
|
||||
filters.add(PreConfiguredCharFilter.singleton("html_strip", false, HTMLStripCharFilter::new));
|
||||
filters.add(PreConfiguredCharFilter.elasticsearchVersion("htmlStrip", false, (reader, version) -> {
|
||||
filters.add(PreConfiguredCharFilter.openSearchVersion("htmlStrip", false, (reader, version) -> {
|
||||
if (version.onOrAfter(org.opensearch.Version.V_6_3_0)) {
|
||||
deprecationLogger.deprecate("htmlStrip_deprecation",
|
||||
"The [htmpStrip] char filter name is deprecated and will be removed in a future version. "
|
||||
|
@ -438,7 +438,7 @@ public class CommonAnalysisPlugin extends Plugin implements AnalysisPlugin, Scri
|
|||
input -> new CommonGramsFilter(input, CharArraySet.EMPTY_SET)));
|
||||
filters.add(PreConfiguredTokenFilter.singleton("czech_stem", false, CzechStemFilter::new));
|
||||
filters.add(PreConfiguredTokenFilter.singleton("decimal_digit", true, DecimalDigitFilter::new));
|
||||
filters.add(PreConfiguredTokenFilter.elasticsearchVersion("delimited_payload_filter", false, (input, version) -> {
|
||||
filters.add(PreConfiguredTokenFilter.openSearchVersion("delimited_payload_filter", false, (input, version) -> {
|
||||
if (version.onOrAfter(Version.V_7_0_0)) {
|
||||
throw new IllegalArgumentException(
|
||||
"[delimited_payload_filter] is not supported for new indices, use [delimited_payload] instead");
|
||||
|
@ -458,7 +458,7 @@ public class CommonAnalysisPlugin extends Plugin implements AnalysisPlugin, Scri
|
|||
filters.add(PreConfiguredTokenFilter.singleton("dutch_stem", false, input -> new SnowballFilter(input, new DutchStemmer())));
|
||||
filters.add(PreConfiguredTokenFilter.singleton("edge_ngram", false, false, input ->
|
||||
new EdgeNGramTokenFilter(input, 1)));
|
||||
filters.add(PreConfiguredTokenFilter.elasticsearchVersion("edgeNGram", false, false, (reader, version) -> {
|
||||
filters.add(PreConfiguredTokenFilter.openSearchVersion("edgeNGram", false, false, (reader, version) -> {
|
||||
if (version.onOrAfter(org.opensearch.Version.V_7_0_0)) {
|
||||
throw new IllegalArgumentException(
|
||||
"The [edgeNGram] token filter name was deprecated in 6.4 and cannot be used in new indices. "
|
||||
|
@ -486,7 +486,7 @@ public class CommonAnalysisPlugin extends Plugin implements AnalysisPlugin, Scri
|
|||
LimitTokenCountFilterFactory.DEFAULT_MAX_TOKEN_COUNT,
|
||||
LimitTokenCountFilterFactory.DEFAULT_CONSUME_ALL_TOKENS)));
|
||||
filters.add(PreConfiguredTokenFilter.singleton("ngram", false, false, reader -> new NGramTokenFilter(reader, 1, 2, false)));
|
||||
filters.add(PreConfiguredTokenFilter.elasticsearchVersion("nGram", false, false, (reader, version) -> {
|
||||
filters.add(PreConfiguredTokenFilter.openSearchVersion("nGram", false, false, (reader, version) -> {
|
||||
if (version.onOrAfter(org.opensearch.Version.V_7_0_0)) {
|
||||
throw new IllegalArgumentException("The [nGram] token filter name was deprecated in 6.4 and cannot be used in new indices. "
|
||||
+ "Please change the filter name to [ngram] instead.");
|
||||
|
@ -532,7 +532,7 @@ public class CommonAnalysisPlugin extends Plugin implements AnalysisPlugin, Scri
|
|||
| WordDelimiterFilter.SPLIT_ON_CASE_CHANGE
|
||||
| WordDelimiterFilter.SPLIT_ON_NUMERICS
|
||||
| WordDelimiterFilter.STEM_ENGLISH_POSSESSIVE, null)));
|
||||
filters.add(PreConfiguredTokenFilter.elasticsearchVersion("word_delimiter_graph", false, false, (input, version) -> {
|
||||
filters.add(PreConfiguredTokenFilter.openSearchVersion("word_delimiter_graph", false, false, (input, version) -> {
|
||||
boolean adjustOffsets = version.onOrAfter(Version.V_7_3_0);
|
||||
return new WordDelimiterGraphFilter(input, adjustOffsets, WordDelimiterIterator.DEFAULT_WORD_DELIM_TABLE,
|
||||
WordDelimiterGraphFilter.GENERATE_WORD_PARTS
|
||||
|
@ -554,7 +554,7 @@ public class CommonAnalysisPlugin extends Plugin implements AnalysisPlugin, Scri
|
|||
tokenizers.add(PreConfiguredTokenizer.singleton("letter", LetterTokenizer::new));
|
||||
tokenizers.add(PreConfiguredTokenizer.singleton("whitespace", WhitespaceTokenizer::new));
|
||||
tokenizers.add(PreConfiguredTokenizer.singleton("ngram", NGramTokenizer::new));
|
||||
tokenizers.add(PreConfiguredTokenizer.elasticsearchVersion("edge_ngram", (version) -> {
|
||||
tokenizers.add(PreConfiguredTokenizer.openSearchVersion("edge_ngram", (version) -> {
|
||||
if (version.onOrAfter(Version.V_7_3_0)) {
|
||||
return new EdgeNGramTokenizer(NGramTokenizer.DEFAULT_MIN_NGRAM_SIZE, NGramTokenizer.DEFAULT_MAX_NGRAM_SIZE);
|
||||
}
|
||||
|
@ -567,7 +567,7 @@ public class CommonAnalysisPlugin extends Plugin implements AnalysisPlugin, Scri
|
|||
tokenizers.add(PreConfiguredTokenizer.singleton("lowercase", XLowerCaseTokenizer::new));
|
||||
|
||||
// Temporary shim for aliases. TODO deprecate after they are moved
|
||||
tokenizers.add(PreConfiguredTokenizer.elasticsearchVersion("nGram", (version) -> {
|
||||
tokenizers.add(PreConfiguredTokenizer.openSearchVersion("nGram", (version) -> {
|
||||
if (version.onOrAfter(org.opensearch.Version.V_7_6_0)) {
|
||||
deprecationLogger.deprecate("nGram_tokenizer_deprecation",
|
||||
"The [nGram] tokenizer name is deprecated and will be removed in a future version. "
|
||||
|
@ -575,7 +575,7 @@ public class CommonAnalysisPlugin extends Plugin implements AnalysisPlugin, Scri
|
|||
}
|
||||
return new NGramTokenizer();
|
||||
}));
|
||||
tokenizers.add(PreConfiguredTokenizer.elasticsearchVersion("edgeNGram", (version) -> {
|
||||
tokenizers.add(PreConfiguredTokenizer.openSearchVersion("edgeNGram", (version) -> {
|
||||
if (version.onOrAfter(org.opensearch.Version.V_7_6_0)) {
|
||||
deprecationLogger.deprecate("edgeNGram_tokenizer_deprecation",
|
||||
"The [edgeNGram] tokenizer name is deprecated and will be removed in a future version. "
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
|
||||
package org.opensearch.index.reindex;
|
||||
|
||||
import org.elasticsearch.watcher.ResourceWatcherService;
|
||||
import org.opensearch.watcher.ResourceWatcherService;
|
||||
import org.opensearch.action.ActionRequest;
|
||||
import org.opensearch.action.ActionResponse;
|
||||
import org.opensearch.client.Client;
|
||||
|
|
|
@ -85,4 +85,4 @@ setup:
|
|||
match_all: {}
|
||||
|
||||
- is_false: valid
|
||||
- match: {error: 'org.elasticsearch.common.ParsingException: request does not support [match_all]'}
|
||||
- match: {error: 'org.opensearch.common.ParsingException: request does not support [match_all]'}
|
||||
|
|
|
@ -22,7 +22,7 @@ import org.opensearch.common.geo.parsers.ShapeParser;
|
|||
import org.opensearch.common.xcontent.XContentBuilder;
|
||||
import org.opensearch.common.xcontent.XContentParser;
|
||||
import org.opensearch.geometry.utils.GeographyValidator;
|
||||
import org.elasticsearch.index.mapper.GeoShapeIndexer;
|
||||
import org.opensearch.index.mapper.GeoShapeIndexer;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.opensearch.test.hamcrest.OpenSearchGeoAssertions;
|
||||
import org.locationtech.jts.geom.Geometry;
|
||||
|
|
|
@ -35,10 +35,10 @@ import org.opensearch.geometry.GeometryCollection;
|
|||
import org.opensearch.geometry.Line;
|
||||
import org.opensearch.geometry.MultiLine;
|
||||
import org.opensearch.geometry.MultiPoint;
|
||||
import org.elasticsearch.index.mapper.ContentPath;
|
||||
import org.elasticsearch.index.mapper.GeoShapeIndexer;
|
||||
import org.elasticsearch.index.mapper.LegacyGeoShapeFieldMapper;
|
||||
import org.elasticsearch.index.mapper.Mapper;
|
||||
import org.opensearch.index.mapper.ContentPath;
|
||||
import org.opensearch.index.mapper.GeoShapeIndexer;
|
||||
import org.opensearch.index.mapper.LegacyGeoShapeFieldMapper;
|
||||
import org.opensearch.index.mapper.Mapper;
|
||||
import org.opensearch.test.VersionUtils;
|
||||
import org.opensearch.test.hamcrest.OpenSearchGeoAssertions;
|
||||
import org.locationtech.jts.geom.Coordinate;
|
||||
|
|
|
@ -45,11 +45,11 @@ import org.opensearch.geometry.GeometryCollection;
|
|||
import org.opensearch.geometry.Line;
|
||||
import org.opensearch.geometry.MultiLine;
|
||||
import org.opensearch.geometry.MultiPoint;
|
||||
import org.elasticsearch.index.mapper.ContentPath;
|
||||
import org.elasticsearch.index.mapper.GeoShapeFieldMapper;
|
||||
import org.elasticsearch.index.mapper.GeoShapeIndexer;
|
||||
import org.elasticsearch.index.mapper.LegacyGeoShapeFieldMapper;
|
||||
import org.elasticsearch.index.mapper.Mapper;
|
||||
import org.opensearch.index.mapper.ContentPath;
|
||||
import org.opensearch.index.mapper.GeoShapeFieldMapper;
|
||||
import org.opensearch.index.mapper.GeoShapeIndexer;
|
||||
import org.opensearch.index.mapper.LegacyGeoShapeFieldMapper;
|
||||
import org.opensearch.index.mapper.Mapper;
|
||||
import org.opensearch.test.geo.RandomShapeGenerator;
|
||||
import org.locationtech.jts.geom.Coordinate;
|
||||
import org.locationtech.jts.geom.LineString;
|
||||
|
|
|
@ -30,7 +30,7 @@ import org.opensearch.geometry.ShapeType;
|
|||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import static org.opensearch.geo.GeometryTestUtils.randomGeometry;
|
||||
import static org.elasticsearch.index.query.LegacyGeoShapeQueryProcessor.geometryToShapeBuilder;
|
||||
import static org.opensearch.index.query.LegacyGeoShapeQueryProcessor.geometryToShapeBuilder;
|
||||
|
||||
public class GeometryIOTests extends OpenSearchTestCase {
|
||||
|
||||
|
|
|
@ -46,7 +46,7 @@ import org.opensearch.geometry.MultiPolygon;
|
|||
import org.opensearch.geometry.Point;
|
||||
import org.opensearch.geometry.Polygon;
|
||||
import org.opensearch.geometry.Rectangle;
|
||||
import org.elasticsearch.index.mapper.GeoShapeIndexer;
|
||||
import org.opensearch.index.mapper.GeoShapeIndexer;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.locationtech.spatial4j.exception.InvalidShapeException;
|
||||
|
||||
|
|
|
@ -28,7 +28,7 @@ import org.opensearch.common.geo.builders.PointBuilder;
|
|||
import org.opensearch.common.geo.builders.PolygonBuilder;
|
||||
import org.opensearch.common.geo.builders.ShapeBuilder;
|
||||
import org.opensearch.geometry.LinearRing;
|
||||
import org.elasticsearch.index.mapper.GeoShapeIndexer;
|
||||
import org.opensearch.index.mapper.GeoShapeIndexer;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.locationtech.jts.geom.Coordinate;
|
||||
import org.locationtech.jts.geom.LineString;
|
||||
|
|
|
@ -22,7 +22,7 @@ package org.opensearch.common.io.stream;
|
|||
import org.opensearch.common.settings.Settings;
|
||||
import org.opensearch.common.util.MockBigArrays;
|
||||
import org.opensearch.common.util.MockPageCacheRecycler;
|
||||
import org.elasticsearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import java.io.IOException;
|
||||
|
|
|
@ -23,8 +23,6 @@ import org.apache.logging.log4j.LogManager;
|
|||
import org.apache.logging.log4j.core.LogEvent;
|
||||
import org.apache.logging.log4j.core.impl.Log4jLogEvent;
|
||||
import org.apache.logging.log4j.message.SimpleMessage;
|
||||
import org.elasticsearch.common.logging.JsonLogLine;
|
||||
import org.elasticsearch.common.logging.JsonLogsStream;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.hamcrest.Matchers;
|
||||
|
||||
|
|
|
@ -62,11 +62,11 @@ import org.apache.lucene.util.BytesRef;
|
|||
import org.opensearch.common.collect.Tuple;
|
||||
import org.opensearch.common.io.stream.NamedWriteableRegistry;
|
||||
import org.opensearch.core.internal.io.IOUtils;
|
||||
import org.elasticsearch.index.fielddata.IndexFieldData;
|
||||
import org.elasticsearch.index.fielddata.fieldcomparator.BytesRefFieldComparatorSource;
|
||||
import org.elasticsearch.index.fielddata.fieldcomparator.DoubleValuesComparatorSource;
|
||||
import org.elasticsearch.index.fielddata.fieldcomparator.FloatValuesComparatorSource;
|
||||
import org.elasticsearch.index.fielddata.fieldcomparator.LongValuesComparatorSource;
|
||||
import org.opensearch.index.fielddata.IndexFieldData;
|
||||
import org.opensearch.index.fielddata.fieldcomparator.BytesRefFieldComparatorSource;
|
||||
import org.opensearch.index.fielddata.fieldcomparator.DoubleValuesComparatorSource;
|
||||
import org.opensearch.index.fielddata.fieldcomparator.FloatValuesComparatorSource;
|
||||
import org.opensearch.index.fielddata.fieldcomparator.LongValuesComparatorSource;
|
||||
import org.opensearch.search.MultiValueMode;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.opensearch.test.VersionUtils;
|
||||
|
|
|
@ -28,7 +28,7 @@ import org.apache.lucene.index.RandomIndexWriter;
|
|||
import org.apache.lucene.store.AlreadyClosedException;
|
||||
import org.apache.lucene.store.Directory;
|
||||
import org.opensearch.common.lucene.index.OpenSearchDirectoryReader;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import java.io.IOException;
|
||||
|
|
|
@ -29,7 +29,7 @@ import org.apache.lucene.index.NoMergePolicy;
|
|||
import org.apache.lucene.index.Term;
|
||||
import org.apache.lucene.store.Directory;
|
||||
import org.opensearch.core.internal.io.IOUtils;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
/** Simple tests for this filterreader */
|
||||
|
|
|
@ -27,7 +27,7 @@ import org.apache.lucene.search.DocValuesFieldExistsQuery;
|
|||
import org.apache.lucene.search.MatchAllDocsQuery;
|
||||
import org.apache.lucene.search.TermQuery;
|
||||
import org.opensearch.Version;
|
||||
import org.elasticsearch.index.mapper.SeqNoFieldMapper;
|
||||
import org.opensearch.index.mapper.SeqNoFieldMapper;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.opensearch.test.VersionUtils;
|
||||
|
||||
|
|
|
@ -19,7 +19,6 @@
|
|||
|
||||
package org.opensearch.common.lucene.store;
|
||||
|
||||
import org.elasticsearch.common.lucene.store.ESIndexInputTestCase;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
|
|
|
@ -32,9 +32,9 @@ import org.apache.lucene.store.Directory;
|
|||
import org.apache.lucene.util.BytesRef;
|
||||
import org.opensearch.common.lucene.Lucene;
|
||||
import org.opensearch.common.lucene.uid.VersionsAndSeqNoResolver.DocIdAndVersion;
|
||||
import org.elasticsearch.index.mapper.IdFieldMapper;
|
||||
import org.elasticsearch.index.mapper.SeqNoFieldMapper;
|
||||
import org.elasticsearch.index.mapper.VersionFieldMapper;
|
||||
import org.opensearch.index.mapper.IdFieldMapper;
|
||||
import org.opensearch.index.mapper.SeqNoFieldMapper;
|
||||
import org.opensearch.index.mapper.VersionFieldMapper;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
/**
|
||||
|
|
|
@ -29,10 +29,10 @@ import org.apache.lucene.store.Directory;
|
|||
import org.opensearch.Version;
|
||||
import org.opensearch.common.lucene.Lucene;
|
||||
import org.opensearch.common.lucene.index.OpenSearchDirectoryReader;
|
||||
import org.elasticsearch.index.mapper.IdFieldMapper;
|
||||
import org.elasticsearch.index.mapper.SeqNoFieldMapper;
|
||||
import org.elasticsearch.index.mapper.VersionFieldMapper;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.opensearch.index.mapper.IdFieldMapper;
|
||||
import org.opensearch.index.mapper.SeqNoFieldMapper;
|
||||
import org.opensearch.index.mapper.VersionFieldMapper;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.opensearch.test.VersionUtils;
|
||||
|
||||
|
|
|
@ -32,7 +32,7 @@ import org.opensearch.http.HttpInfo;
|
|||
import org.opensearch.http.HttpServerTransport;
|
||||
import org.opensearch.http.HttpStats;
|
||||
import org.opensearch.http.NullDispatcher;
|
||||
import org.elasticsearch.indices.breaker.CircuitBreakerService;
|
||||
import org.opensearch.indices.breaker.CircuitBreakerService;
|
||||
import org.opensearch.plugins.NetworkPlugin;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.opensearch.threadpool.TestThreadPool;
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
|
||||
package org.opensearch.common.settings;
|
||||
|
||||
import org.elasticsearch.common.settings.MockSecureSettings;
|
||||
import org.opensearch.common.settings.MockSecureSettings;
|
||||
import org.opensearch.cluster.ClusterState;
|
||||
import org.opensearch.cluster.ClusterStateUpdateTask;
|
||||
import org.opensearch.cluster.service.ClusterService;
|
||||
|
|
|
@ -23,12 +23,12 @@ import org.opensearch.common.settings.Setting.Property;
|
|||
import org.opensearch.common.unit.ByteSizeUnit;
|
||||
import org.opensearch.common.unit.ByteSizeValue;
|
||||
import org.opensearch.common.util.PageCacheRecycler;
|
||||
import org.elasticsearch.indices.IndexingMemoryController;
|
||||
import org.elasticsearch.indices.IndicesQueryCache;
|
||||
import org.elasticsearch.indices.IndicesRequestCache;
|
||||
import org.elasticsearch.indices.breaker.HierarchyCircuitBreakerService;
|
||||
import org.elasticsearch.indices.fielddata.cache.IndicesFieldDataCache;
|
||||
import org.elasticsearch.monitor.jvm.JvmInfo;
|
||||
import org.opensearch.indices.IndexingMemoryController;
|
||||
import org.opensearch.indices.IndicesQueryCache;
|
||||
import org.opensearch.indices.IndicesRequestCache;
|
||||
import org.opensearch.indices.breaker.HierarchyCircuitBreakerService;
|
||||
import org.opensearch.indices.fielddata.cache.IndicesFieldDataCache;
|
||||
import org.opensearch.monitor.jvm.JvmInfo;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import static org.hamcrest.Matchers.notNullValue;
|
||||
|
|
|
@ -20,7 +20,6 @@ package org.opensearch.common.settings;
|
|||
|
||||
import org.apache.logging.log4j.Level;
|
||||
import org.apache.logging.log4j.LogManager;
|
||||
import org.elasticsearch.common.settings.MockSecureSettings;
|
||||
import org.opensearch.Version;
|
||||
import org.opensearch.cluster.metadata.IndexMetadata;
|
||||
import org.opensearch.cluster.routing.allocation.decider.FilterAllocationDecider;
|
||||
|
|
|
@ -22,7 +22,6 @@ import org.apache.logging.log4j.Level;
|
|||
import org.apache.logging.log4j.LogManager;
|
||||
import org.apache.logging.log4j.Logger;
|
||||
import org.apache.logging.log4j.core.LogEvent;
|
||||
import org.elasticsearch.common.settings.MockSecureSettings;
|
||||
import org.opensearch.cluster.metadata.IndexMetadata;
|
||||
import org.opensearch.common.collect.Tuple;
|
||||
import org.opensearch.common.logging.Loggers;
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
|
||||
package org.opensearch.common.settings;
|
||||
|
||||
import org.elasticsearch.common.settings.MockSecureSettings;
|
||||
import org.opensearch.common.settings.MockSecureSettings;
|
||||
import org.opensearch.OpenSearchParseException;
|
||||
import org.opensearch.Version;
|
||||
import org.opensearch.common.Strings;
|
||||
|
|
|
@ -20,15 +20,15 @@
|
|||
package org.opensearch.common.util;
|
||||
|
||||
import org.apache.lucene.util.BytesRef;
|
||||
import org.elasticsearch.common.util.MockBigArrays;
|
||||
import org.elasticsearch.common.util.MockPageCacheRecycler;
|
||||
import org.opensearch.common.util.MockBigArrays;
|
||||
import org.opensearch.common.util.MockPageCacheRecycler;
|
||||
import org.opensearch.common.breaker.CircuitBreaker;
|
||||
import org.opensearch.common.breaker.CircuitBreakingException;
|
||||
import org.opensearch.common.settings.ClusterSettings;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.opensearch.common.unit.ByteSizeUnit;
|
||||
import org.elasticsearch.indices.breaker.HierarchyCircuitBreakerService;
|
||||
import org.elasticsearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.indices.breaker.HierarchyCircuitBreakerService;
|
||||
import org.opensearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.junit.Before;
|
||||
|
||||
|
@ -39,7 +39,7 @@ import java.util.Collections;
|
|||
import java.util.List;
|
||||
import java.util.function.Function;
|
||||
|
||||
import static org.elasticsearch.indices.breaker.HierarchyCircuitBreakerService.REQUEST_CIRCUIT_BREAKER_LIMIT_SETTING;
|
||||
import static org.opensearch.indices.breaker.HierarchyCircuitBreakerService.REQUEST_CIRCUIT_BREAKER_LIMIT_SETTING;
|
||||
import static org.hamcrest.Matchers.equalTo;
|
||||
import static org.hamcrest.Matchers.greaterThanOrEqualTo;
|
||||
import static org.hamcrest.Matchers.lessThan;
|
||||
|
|
|
@ -19,11 +19,9 @@
|
|||
|
||||
package org.opensearch.common.util;
|
||||
|
||||
import org.elasticsearch.common.util.MockBigArrays;
|
||||
import org.elasticsearch.common.util.MockPageCacheRecycler;
|
||||
import org.opensearch.common.lease.Releasables;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.elasticsearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.junit.Before;
|
||||
|
||||
|
|
|
@ -24,7 +24,7 @@ import org.opensearch.common.breaker.CircuitBreakingException;
|
|||
import org.opensearch.common.breaker.NoopCircuitBreaker;
|
||||
import org.opensearch.common.unit.ByteSizeUnit;
|
||||
import org.opensearch.common.unit.ByteSizeValue;
|
||||
import org.elasticsearch.indices.breaker.CircuitBreakerService;
|
||||
import org.opensearch.indices.breaker.CircuitBreakerService;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
|
|
@ -25,10 +25,8 @@ import com.carrotsearch.hppc.cursors.ObjectLongCursor;
|
|||
import org.apache.lucene.util.BytesRef;
|
||||
import org.apache.lucene.util.BytesRefBuilder;
|
||||
import org.apache.lucene.util.TestUtil;
|
||||
import org.elasticsearch.common.util.MockBigArrays;
|
||||
import org.elasticsearch.common.util.MockPageCacheRecycler;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.elasticsearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
|
|
@ -23,10 +23,8 @@ import com.carrotsearch.hppc.LongLongHashMap;
|
|||
import com.carrotsearch.hppc.LongLongMap;
|
||||
import com.carrotsearch.hppc.cursors.LongLongCursor;
|
||||
|
||||
import org.elasticsearch.common.util.MockBigArrays;
|
||||
import org.elasticsearch.common.util.MockPageCacheRecycler;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.elasticsearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
|
|
@ -19,10 +19,8 @@
|
|||
|
||||
package org.opensearch.common.util;
|
||||
|
||||
import org.elasticsearch.common.util.MockBigArrays;
|
||||
import org.elasticsearch.common.util.MockPageCacheRecycler;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.elasticsearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
|
|
@ -20,10 +20,8 @@
|
|||
package org.opensearch.common.util;
|
||||
|
||||
import com.carrotsearch.hppc.LongObjectHashMap;
|
||||
import org.elasticsearch.common.util.MockBigArrays;
|
||||
import org.elasticsearch.common.util.MockPageCacheRecycler;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.elasticsearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
public class LongObjectHashMapTests extends OpenSearchTestCase {
|
||||
|
|
|
@ -25,18 +25,6 @@ import com.fasterxml.jackson.core.JsonParseException;
|
|||
|
||||
import org.apache.lucene.util.BytesRef;
|
||||
import org.apache.lucene.util.Constants;
|
||||
import org.elasticsearch.common.xcontent.DeprecationHandler;
|
||||
import org.elasticsearch.common.xcontent.NamedObjectNotFoundException;
|
||||
import org.elasticsearch.common.xcontent.NamedXContentRegistry;
|
||||
import org.elasticsearch.common.xcontent.ToXContent;
|
||||
import org.elasticsearch.common.xcontent.ToXContentObject;
|
||||
import org.elasticsearch.common.xcontent.XContent;
|
||||
import org.elasticsearch.common.xcontent.XContentBuilder;
|
||||
import org.elasticsearch.common.xcontent.XContentFactory;
|
||||
import org.elasticsearch.common.xcontent.XContentGenerator;
|
||||
import org.elasticsearch.common.xcontent.XContentParseException;
|
||||
import org.elasticsearch.common.xcontent.XContentParser;
|
||||
import org.elasticsearch.common.xcontent.XContentType;
|
||||
import org.opensearch.cluster.metadata.IndexMetadata;
|
||||
import org.opensearch.common.ParseField;
|
||||
import org.opensearch.common.Strings;
|
||||
|
|
|
@ -21,9 +21,6 @@ package org.opensearch.common.xcontent;
|
|||
|
||||
import com.fasterxml.jackson.dataformat.cbor.CBORConstants;
|
||||
import com.fasterxml.jackson.dataformat.smile.SmileConstants;
|
||||
import org.elasticsearch.common.xcontent.XContentBuilder;
|
||||
import org.elasticsearch.common.xcontent.XContentFactory;
|
||||
import org.elasticsearch.common.xcontent.XContentType;
|
||||
import org.opensearch.common.Strings;
|
||||
import org.opensearch.common.bytes.BytesArray;
|
||||
import org.opensearch.common.bytes.BytesReference;
|
||||
|
|
|
@ -20,13 +20,6 @@
|
|||
package org.opensearch.common.xcontent;
|
||||
|
||||
import org.apache.lucene.util.SetOnce;
|
||||
import org.elasticsearch.common.xcontent.DeprecationHandler;
|
||||
import org.elasticsearch.common.xcontent.NamedObjectNotFoundException;
|
||||
import org.elasticsearch.common.xcontent.NamedXContentRegistry;
|
||||
import org.elasticsearch.common.xcontent.ObjectParser;
|
||||
import org.elasticsearch.common.xcontent.XContentBuilder;
|
||||
import org.elasticsearch.common.xcontent.XContentParser;
|
||||
import org.elasticsearch.common.xcontent.XContentType;
|
||||
import org.opensearch.common.CheckedBiConsumer;
|
||||
import org.opensearch.common.CheckedConsumer;
|
||||
import org.opensearch.common.ParseField;
|
||||
|
|
|
@ -18,7 +18,6 @@
|
|||
*/
|
||||
package org.opensearch.common.xcontent;
|
||||
|
||||
import org.elasticsearch.common.xcontent.XContentType;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import java.util.Locale;
|
||||
|
|
|
@ -19,7 +19,6 @@
|
|||
|
||||
package org.opensearch.common.xcontent.cbor;
|
||||
|
||||
import org.elasticsearch.common.xcontent.cbor.CborXContent;
|
||||
import org.opensearch.common.bytes.BytesReference;
|
||||
import org.opensearch.common.xcontent.XContentFactory;
|
||||
import org.opensearch.common.xcontent.XContentParser;
|
||||
|
|
|
@ -19,7 +19,6 @@
|
|||
|
||||
package org.opensearch.common.xcontent.cbor;
|
||||
|
||||
import org.elasticsearch.common.xcontent.cbor.CborXContent;
|
||||
import org.opensearch.common.io.stream.BytesStreamOutput;
|
||||
import org.opensearch.common.xcontent.XContentFactory;
|
||||
import org.opensearch.common.xcontent.XContentGenerator;
|
||||
|
|
|
@ -19,7 +19,6 @@
|
|||
|
||||
package org.opensearch.common.xcontent.smile;
|
||||
|
||||
import org.elasticsearch.common.xcontent.smile.SmileXContent;
|
||||
import org.opensearch.common.io.stream.BytesStreamOutput;
|
||||
import org.opensearch.common.xcontent.XContentFactory;
|
||||
import org.opensearch.common.xcontent.XContentGenerator;
|
||||
|
|
|
@ -22,7 +22,6 @@ package org.opensearch.common.xcontent.support.filtering;
|
|||
import com.fasterxml.jackson.core.JsonFactory;
|
||||
import com.fasterxml.jackson.core.JsonParser;
|
||||
import com.fasterxml.jackson.core.filter.FilteringGeneratorDelegate;
|
||||
import org.elasticsearch.common.xcontent.support.filtering.FilterPathBasedFilter;
|
||||
import org.opensearch.common.io.stream.BytesStreamOutput;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
|
|
|
@ -19,7 +19,6 @@
|
|||
|
||||
package org.opensearch.common.xcontent.support.filtering;
|
||||
|
||||
import org.elasticsearch.common.xcontent.support.filtering.FilterPath;
|
||||
import org.opensearch.common.util.set.Sets;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
|
|
|
@ -26,13 +26,13 @@ import org.opensearch.common.settings.Settings;
|
|||
import org.opensearch.common.unit.ByteSizeUnit;
|
||||
import org.opensearch.common.unit.ByteSizeValue;
|
||||
import org.opensearch.common.xcontent.XContentType;
|
||||
import org.elasticsearch.index.codec.CodecService;
|
||||
import org.elasticsearch.index.engine.EngineConfig;
|
||||
import org.elasticsearch.index.engine.InternalEngine;
|
||||
import org.elasticsearch.index.refresh.RefreshStats;
|
||||
import org.elasticsearch.index.shard.IndexShard;
|
||||
import org.opensearch.index.codec.CodecService;
|
||||
import org.opensearch.index.engine.EngineConfig;
|
||||
import org.opensearch.index.engine.InternalEngine;
|
||||
import org.opensearch.index.refresh.RefreshStats;
|
||||
import org.opensearch.index.shard.IndexShard;
|
||||
import org.opensearch.index.shard.IndexShardTestCase;
|
||||
import org.elasticsearch.indices.recovery.RecoveryState;
|
||||
import org.opensearch.indices.recovery.RecoveryState;
|
||||
import org.opensearch.threadpool.Scheduler.Cancellable;
|
||||
import org.opensearch.threadpool.ThreadPool;
|
||||
import org.opensearch.threadpool.ThreadPoolStats;
|
||||
|
|
|
@ -26,16 +26,16 @@ import org.opensearch.cluster.routing.ShardRouting;
|
|||
import org.opensearch.cluster.routing.ShardRoutingHelper;
|
||||
import org.opensearch.cluster.routing.UnassignedInfo;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.elasticsearch.index.Index;
|
||||
import org.elasticsearch.index.IndexService;
|
||||
import org.elasticsearch.index.IndexSettings;
|
||||
import org.elasticsearch.index.seqno.RetentionLeaseSyncer;
|
||||
import org.elasticsearch.index.shard.IndexEventListener;
|
||||
import org.elasticsearch.index.shard.IndexShard;
|
||||
import org.opensearch.index.Index;
|
||||
import org.opensearch.index.IndexService;
|
||||
import org.opensearch.index.IndexSettings;
|
||||
import org.opensearch.index.seqno.RetentionLeaseSyncer;
|
||||
import org.opensearch.index.shard.IndexEventListener;
|
||||
import org.opensearch.index.shard.IndexShard;
|
||||
import org.opensearch.index.shard.IndexShardTestCase;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.elasticsearch.indices.cluster.IndicesClusterStateService.AllocatedIndices.IndexRemovalReason;
|
||||
import org.elasticsearch.indices.recovery.RecoveryState;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.indices.cluster.IndicesClusterStateService.AllocatedIndices.IndexRemovalReason;
|
||||
import org.opensearch.indices.recovery.RecoveryState;
|
||||
import org.opensearch.test.OpenSearchSingleNodeTestCase;
|
||||
|
||||
import java.util.Arrays;
|
||||
|
@ -45,7 +45,7 @@ import static java.util.Collections.emptyMap;
|
|||
import static java.util.Collections.emptySet;
|
||||
import static org.opensearch.cluster.metadata.IndexMetadata.SETTING_NUMBER_OF_REPLICAS;
|
||||
import static org.opensearch.cluster.metadata.IndexMetadata.SETTING_NUMBER_OF_SHARDS;
|
||||
import static org.elasticsearch.indices.cluster.IndicesClusterStateService.AllocatedIndices.IndexRemovalReason.DELETED;
|
||||
import static org.opensearch.indices.cluster.IndicesClusterStateService.AllocatedIndices.IndexRemovalReason.DELETED;
|
||||
import static org.opensearch.test.hamcrest.OpenSearchAssertions.assertAcked;
|
||||
|
||||
public class IndicesLifecycleListenerSingleNodeTests extends OpenSearchSingleNodeTestCase {
|
||||
|
|
|
@ -20,21 +20,21 @@
|
|||
package org.opensearch.indices;
|
||||
|
||||
import org.opensearch.Version;
|
||||
import org.elasticsearch.index.mapper.AllFieldMapper;
|
||||
import org.elasticsearch.index.mapper.FieldNamesFieldMapper;
|
||||
import org.elasticsearch.index.mapper.IdFieldMapper;
|
||||
import org.elasticsearch.index.mapper.IgnoredFieldMapper;
|
||||
import org.elasticsearch.index.mapper.IndexFieldMapper;
|
||||
import org.elasticsearch.index.mapper.Mapper;
|
||||
import org.elasticsearch.index.mapper.MapperParsingException;
|
||||
import org.elasticsearch.index.mapper.MetadataFieldMapper;
|
||||
import org.elasticsearch.index.mapper.RoutingFieldMapper;
|
||||
import org.elasticsearch.index.mapper.SeqNoFieldMapper;
|
||||
import org.elasticsearch.index.mapper.SourceFieldMapper;
|
||||
import org.elasticsearch.index.mapper.TextFieldMapper;
|
||||
import org.elasticsearch.index.mapper.TypeFieldMapper;
|
||||
import org.elasticsearch.index.mapper.VersionFieldMapper;
|
||||
import org.elasticsearch.indices.mapper.MapperRegistry;
|
||||
import org.opensearch.index.mapper.AllFieldMapper;
|
||||
import org.opensearch.index.mapper.FieldNamesFieldMapper;
|
||||
import org.opensearch.index.mapper.IdFieldMapper;
|
||||
import org.opensearch.index.mapper.IgnoredFieldMapper;
|
||||
import org.opensearch.index.mapper.IndexFieldMapper;
|
||||
import org.opensearch.index.mapper.Mapper;
|
||||
import org.opensearch.index.mapper.MapperParsingException;
|
||||
import org.opensearch.index.mapper.MetadataFieldMapper;
|
||||
import org.opensearch.index.mapper.RoutingFieldMapper;
|
||||
import org.opensearch.index.mapper.SeqNoFieldMapper;
|
||||
import org.opensearch.index.mapper.SourceFieldMapper;
|
||||
import org.opensearch.index.mapper.TextFieldMapper;
|
||||
import org.opensearch.index.mapper.TypeFieldMapper;
|
||||
import org.opensearch.index.mapper.VersionFieldMapper;
|
||||
import org.opensearch.indices.mapper.MapperRegistry;
|
||||
import org.opensearch.plugins.MapperPlugin;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.opensearch.test.VersionUtils;
|
||||
|
|
|
@ -40,8 +40,8 @@ import org.apache.lucene.store.Directory;
|
|||
import org.opensearch.common.lucene.index.OpenSearchDirectoryReader;
|
||||
import org.opensearch.core.internal.io.IOUtils;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.elasticsearch.index.cache.query.QueryCacheStats;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.opensearch.index.cache.query.QueryCacheStats;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import java.io.IOException;
|
||||
|
|
|
@ -28,14 +28,14 @@ import org.opensearch.common.bytes.BytesReference;
|
|||
import org.opensearch.common.cache.RemovalNotification;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.opensearch.common.util.concurrent.OpenSearchExecutors;
|
||||
import org.elasticsearch.env.Environment;
|
||||
import org.elasticsearch.env.NodeEnvironment;
|
||||
import org.elasticsearch.index.IndexModule;
|
||||
import org.elasticsearch.index.IndexService;
|
||||
import org.elasticsearch.index.engine.Engine;
|
||||
import org.elasticsearch.index.shard.IndexShard;
|
||||
import org.elasticsearch.indices.IndicesRequestCache.Key;
|
||||
import org.elasticsearch.indices.breaker.HierarchyCircuitBreakerService;
|
||||
import org.opensearch.env.Environment;
|
||||
import org.opensearch.env.NodeEnvironment;
|
||||
import org.opensearch.index.IndexModule;
|
||||
import org.opensearch.index.IndexService;
|
||||
import org.opensearch.index.engine.Engine;
|
||||
import org.opensearch.index.shard.IndexShard;
|
||||
import org.opensearch.indices.IndicesRequestCache.Key;
|
||||
import org.opensearch.indices.breaker.HierarchyCircuitBreakerService;
|
||||
import org.opensearch.node.MockNode;
|
||||
import org.opensearch.node.Node;
|
||||
import org.opensearch.node.NodeValidationException;
|
||||
|
|
|
@ -36,30 +36,30 @@ import org.opensearch.common.io.FileSystemUtils;
|
|||
import org.opensearch.common.settings.Setting;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.opensearch.common.unit.TimeValue;
|
||||
import org.elasticsearch.env.NodeEnvironment;
|
||||
import org.elasticsearch.env.ShardLockObtainFailedException;
|
||||
import org.opensearch.env.NodeEnvironment;
|
||||
import org.opensearch.env.ShardLockObtainFailedException;
|
||||
import org.opensearch.gateway.GatewayMetaState;
|
||||
import org.opensearch.gateway.LocalAllocateDangledIndices;
|
||||
import org.opensearch.gateway.MetaStateService;
|
||||
import org.elasticsearch.index.Index;
|
||||
import org.elasticsearch.index.IndexModule;
|
||||
import org.elasticsearch.index.IndexService;
|
||||
import org.elasticsearch.index.IndexSettings;
|
||||
import org.elasticsearch.index.engine.Engine;
|
||||
import org.elasticsearch.index.engine.EngineConfig;
|
||||
import org.elasticsearch.index.engine.EngineFactory;
|
||||
import org.elasticsearch.index.engine.InternalEngine;
|
||||
import org.elasticsearch.index.engine.InternalEngineFactory;
|
||||
import org.elasticsearch.index.mapper.KeywordFieldMapper;
|
||||
import org.elasticsearch.index.mapper.Mapper;
|
||||
import org.elasticsearch.index.mapper.MapperService;
|
||||
import org.elasticsearch.index.shard.IllegalIndexShardStateException;
|
||||
import org.elasticsearch.index.shard.IndexShard;
|
||||
import org.elasticsearch.index.shard.IndexShardState;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.elasticsearch.index.shard.ShardPath;
|
||||
import org.elasticsearch.index.similarity.NonNegativeScoresSimilarity;
|
||||
import org.elasticsearch.indices.IndicesService.ShardDeletionCheckResult;
|
||||
import org.opensearch.index.Index;
|
||||
import org.opensearch.index.IndexModule;
|
||||
import org.opensearch.index.IndexService;
|
||||
import org.opensearch.index.IndexSettings;
|
||||
import org.opensearch.index.engine.Engine;
|
||||
import org.opensearch.index.engine.EngineConfig;
|
||||
import org.opensearch.index.engine.EngineFactory;
|
||||
import org.opensearch.index.engine.InternalEngine;
|
||||
import org.opensearch.index.engine.InternalEngineFactory;
|
||||
import org.opensearch.index.mapper.KeywordFieldMapper;
|
||||
import org.opensearch.index.mapper.Mapper;
|
||||
import org.opensearch.index.mapper.MapperService;
|
||||
import org.opensearch.index.shard.IllegalIndexShardStateException;
|
||||
import org.opensearch.index.shard.IndexShard;
|
||||
import org.opensearch.index.shard.IndexShardState;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.index.shard.ShardPath;
|
||||
import org.opensearch.index.similarity.NonNegativeScoresSimilarity;
|
||||
import org.opensearch.indices.IndicesService.ShardDeletionCheckResult;
|
||||
import org.opensearch.plugins.EnginePlugin;
|
||||
import org.opensearch.plugins.MapperPlugin;
|
||||
import org.opensearch.plugins.Plugin;
|
||||
|
|
|
@ -32,7 +32,7 @@ import org.opensearch.common.ValidationException;
|
|||
import org.opensearch.common.collect.ImmutableOpenMap;
|
||||
import org.opensearch.common.settings.ClusterSettings;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.elasticsearch.index.Index;
|
||||
import org.opensearch.index.Index;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import java.util.Arrays;
|
||||
|
@ -42,7 +42,7 @@ import java.util.stream.Collectors;
|
|||
import static org.opensearch.cluster.metadata.MetadataIndexStateServiceTests.addClosedIndex;
|
||||
import static org.opensearch.cluster.metadata.MetadataIndexStateServiceTests.addOpenedIndex;
|
||||
import static org.opensearch.cluster.shards.ShardCounts.forDataNodeCount;
|
||||
import static org.elasticsearch.indices.ShardLimitValidator.SETTING_CLUSTER_MAX_SHARDS_PER_NODE;
|
||||
import static org.opensearch.indices.ShardLimitValidator.SETTING_CLUSTER_MAX_SHARDS_PER_NODE;
|
||||
import static org.mockito.Mockito.mock;
|
||||
import static org.mockito.Mockito.when;
|
||||
|
||||
|
|
|
@ -35,24 +35,24 @@ import org.opensearch.cluster.metadata.IndexMetadata;
|
|||
import org.opensearch.common.io.Streams;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.opensearch.common.xcontent.XContentType;
|
||||
import org.elasticsearch.env.Environment;
|
||||
import org.opensearch.env.Environment;
|
||||
import org.opensearch.env.TestEnvironment;
|
||||
import org.elasticsearch.index.IndexSettings;
|
||||
import org.elasticsearch.index.analysis.Analysis;
|
||||
import org.elasticsearch.index.analysis.AnalysisRegistry;
|
||||
import org.elasticsearch.index.analysis.CharFilterFactory;
|
||||
import org.elasticsearch.index.analysis.CustomAnalyzer;
|
||||
import org.elasticsearch.index.analysis.IndexAnalyzers;
|
||||
import org.elasticsearch.index.analysis.NamedAnalyzer;
|
||||
import org.elasticsearch.index.analysis.PreConfiguredCharFilter;
|
||||
import org.elasticsearch.index.analysis.PreConfiguredTokenFilter;
|
||||
import org.elasticsearch.index.analysis.PreConfiguredTokenizer;
|
||||
import org.elasticsearch.index.analysis.StandardTokenizerFactory;
|
||||
import org.elasticsearch.index.analysis.StopTokenFilterFactory;
|
||||
import org.elasticsearch.index.analysis.TokenFilterFactory;
|
||||
import org.opensearch.index.IndexSettings;
|
||||
import org.opensearch.index.analysis.Analysis;
|
||||
import org.opensearch.index.analysis.AnalysisRegistry;
|
||||
import org.opensearch.index.analysis.CharFilterFactory;
|
||||
import org.opensearch.index.analysis.CustomAnalyzer;
|
||||
import org.opensearch.index.analysis.IndexAnalyzers;
|
||||
import org.opensearch.index.analysis.NamedAnalyzer;
|
||||
import org.opensearch.index.analysis.PreConfiguredCharFilter;
|
||||
import org.opensearch.index.analysis.PreConfiguredTokenFilter;
|
||||
import org.opensearch.index.analysis.PreConfiguredTokenizer;
|
||||
import org.opensearch.index.analysis.StandardTokenizerFactory;
|
||||
import org.opensearch.index.analysis.StopTokenFilterFactory;
|
||||
import org.opensearch.index.analysis.TokenFilterFactory;
|
||||
import org.opensearch.index.analysis.MyFilterTokenFilterFactory;
|
||||
import org.elasticsearch.index.analysis.TokenizerFactory;
|
||||
import org.elasticsearch.indices.analysis.AnalysisModule.AnalysisProvider;
|
||||
import org.opensearch.index.analysis.TokenizerFactory;
|
||||
import org.opensearch.indices.analysis.AnalysisModule.AnalysisProvider;
|
||||
import org.opensearch.plugins.AnalysisPlugin;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.opensearch.test.IndexSettingsModule;
|
||||
|
@ -269,7 +269,7 @@ public class AnalysisModuleTests extends OpenSearchTestCase {
|
|||
tokenStream -> new AppendCharFilter(tokenStream, "no_version")),
|
||||
PreConfiguredCharFilter.luceneVersion("lucene_version", luceneVersionSupportsMultiTerm,
|
||||
(tokenStream, luceneVersion) -> new AppendCharFilter(tokenStream, luceneVersion.toString())),
|
||||
PreConfiguredCharFilter.elasticsearchVersion("elasticsearch_version", elasticsearchVersionSupportsMultiTerm,
|
||||
PreConfiguredCharFilter.openSearchVersion("elasticsearch_version", elasticsearchVersionSupportsMultiTerm,
|
||||
(tokenStream, esVersion) -> new AppendCharFilter(tokenStream, esVersion.toString()))
|
||||
);
|
||||
}
|
||||
|
@ -321,7 +321,7 @@ public class AnalysisModuleTests extends OpenSearchTestCase {
|
|||
tokenStream -> new AppendTokenFilter(tokenStream, "no_version")),
|
||||
PreConfiguredTokenFilter.luceneVersion("lucene_version", luceneVersionSupportsMultiTerm,
|
||||
(tokenStream, luceneVersion) -> new AppendTokenFilter(tokenStream, luceneVersion.toString())),
|
||||
PreConfiguredTokenFilter.elasticsearchVersion("elasticsearch_version", elasticsearchVersionSupportsMultiTerm,
|
||||
PreConfiguredTokenFilter.openSearchVersion("elasticsearch_version", elasticsearchVersionSupportsMultiTerm,
|
||||
(tokenStream, esVersion) -> new AppendTokenFilter(tokenStream, esVersion.toString()))
|
||||
);
|
||||
}
|
||||
|
@ -392,7 +392,7 @@ public class AnalysisModuleTests extends OpenSearchTestCase {
|
|||
PreConfiguredTokenizer.singleton("no_version", () -> new FixedTokenizer("no_version")),
|
||||
PreConfiguredTokenizer.luceneVersion("lucene_version",
|
||||
luceneVersion -> new FixedTokenizer(luceneVersion.toString())),
|
||||
PreConfiguredTokenizer.elasticsearchVersion("elasticsearch_version",
|
||||
PreConfiguredTokenizer.openSearchVersion("elasticsearch_version",
|
||||
esVersion -> new FixedTokenizer(esVersion.toString()))
|
||||
);
|
||||
}
|
||||
|
|
|
@ -20,15 +20,15 @@ package org.opensearch.indices.analyze;
|
|||
|
||||
import org.apache.lucene.analysis.hunspell.Dictionary;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.elasticsearch.env.Environment;
|
||||
import org.elasticsearch.indices.analysis.HunspellService;
|
||||
import org.opensearch.env.Environment;
|
||||
import org.opensearch.indices.analysis.HunspellService;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import java.nio.file.Path;
|
||||
|
||||
import static java.util.Collections.emptyMap;
|
||||
import static org.elasticsearch.indices.analysis.HunspellService.HUNSPELL_IGNORE_CASE;
|
||||
import static org.elasticsearch.indices.analysis.HunspellService.HUNSPELL_LAZY_LOAD;
|
||||
import static org.opensearch.indices.analysis.HunspellService.HUNSPELL_IGNORE_CASE;
|
||||
import static org.opensearch.indices.analysis.HunspellService.HUNSPELL_LAZY_LOAD;
|
||||
import static org.hamcrest.Matchers.containsString;
|
||||
import static org.hamcrest.Matchers.hasToString;
|
||||
import static org.hamcrest.Matchers.notNullValue;
|
||||
|
|
|
@ -28,7 +28,7 @@ import org.opensearch.common.settings.Settings;
|
|||
import org.opensearch.common.unit.ByteSizeUnit;
|
||||
import org.opensearch.common.unit.ByteSizeValue;
|
||||
import org.opensearch.common.unit.TimeValue;
|
||||
import org.elasticsearch.monitor.jvm.JvmInfo;
|
||||
import org.opensearch.monitor.jvm.JvmInfo;
|
||||
import org.opensearch.search.aggregations.MultiBucketConsumerService;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
|
|
|
@ -29,21 +29,21 @@ import org.opensearch.cluster.routing.ShardRouting;
|
|||
import org.opensearch.common.Nullable;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.opensearch.common.unit.TimeValue;
|
||||
import org.elasticsearch.index.Index;
|
||||
import org.elasticsearch.index.IndexService;
|
||||
import org.elasticsearch.index.IndexSettings;
|
||||
import org.elasticsearch.index.seqno.RetentionLeaseSyncer;
|
||||
import org.elasticsearch.index.shard.IndexEventListener;
|
||||
import org.elasticsearch.index.shard.IndexShard;
|
||||
import org.elasticsearch.index.shard.IndexShardState;
|
||||
import org.elasticsearch.index.shard.PrimaryReplicaSyncer.ResyncTask;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.elasticsearch.indices.IndicesService;
|
||||
import org.elasticsearch.indices.cluster.IndicesClusterStateService.AllocatedIndex;
|
||||
import org.elasticsearch.indices.cluster.IndicesClusterStateService.AllocatedIndices;
|
||||
import org.elasticsearch.indices.cluster.IndicesClusterStateService.Shard;
|
||||
import org.elasticsearch.indices.recovery.PeerRecoveryTargetService;
|
||||
import org.elasticsearch.indices.recovery.RecoveryState;
|
||||
import org.opensearch.index.Index;
|
||||
import org.opensearch.index.IndexService;
|
||||
import org.opensearch.index.IndexSettings;
|
||||
import org.opensearch.index.seqno.RetentionLeaseSyncer;
|
||||
import org.opensearch.index.shard.IndexEventListener;
|
||||
import org.opensearch.index.shard.IndexShard;
|
||||
import org.opensearch.index.shard.IndexShardState;
|
||||
import org.opensearch.index.shard.PrimaryReplicaSyncer.ResyncTask;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.indices.IndicesService;
|
||||
import org.opensearch.indices.cluster.IndicesClusterStateService.AllocatedIndex;
|
||||
import org.opensearch.indices.cluster.IndicesClusterStateService.AllocatedIndices;
|
||||
import org.opensearch.indices.cluster.IndicesClusterStateService.Shard;
|
||||
import org.opensearch.indices.recovery.PeerRecoveryTargetService;
|
||||
import org.opensearch.indices.recovery.RecoveryState;
|
||||
import org.opensearch.repositories.RepositoriesService;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.junit.Before;
|
||||
|
|
|
@ -80,7 +80,7 @@ import org.opensearch.common.CheckedFunction;
|
|||
import org.opensearch.common.UUIDs;
|
||||
import org.opensearch.common.settings.ClusterSettings;
|
||||
import org.opensearch.common.settings.IndexScopedSettings;
|
||||
import org.elasticsearch.common.settings.Settings;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.opensearch.common.util.concurrent.ThreadContext;
|
||||
import org.opensearch.common.xcontent.NamedXContentRegistry;
|
||||
import org.opensearch.env.Environment;
|
||||
|
|
|
@ -28,11 +28,11 @@ import org.opensearch.common.UUIDs;
|
|||
import org.opensearch.common.lease.Releasable;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.opensearch.common.xcontent.XContentType;
|
||||
import org.elasticsearch.index.IndexService;
|
||||
import org.elasticsearch.index.shard.IndexShard;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.elasticsearch.index.shard.ShardNotFoundException;
|
||||
import org.elasticsearch.indices.IndicesService;
|
||||
import org.opensearch.index.IndexService;
|
||||
import org.opensearch.index.shard.IndexShard;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.index.shard.ShardNotFoundException;
|
||||
import org.opensearch.indices.IndicesService;
|
||||
import org.opensearch.test.OpenSearchSingleNodeTestCase;
|
||||
import org.opensearch.threadpool.ThreadPool;
|
||||
|
||||
|
|
|
@ -23,7 +23,7 @@ import org.opensearch.ExceptionsHelper;
|
|||
import org.opensearch.action.ActionListener;
|
||||
import org.opensearch.cluster.ClusterState;
|
||||
import org.opensearch.cluster.routing.ShardRouting;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.test.InternalTestCluster;
|
||||
|
||||
import java.util.List;
|
||||
|
|
|
@ -21,8 +21,8 @@ package org.opensearch.indices.memory.breaker;
|
|||
|
||||
import org.opensearch.common.breaker.CircuitBreaker;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.elasticsearch.indices.breaker.BreakerSettings;
|
||||
import org.elasticsearch.indices.breaker.HierarchyCircuitBreakerService;
|
||||
import org.opensearch.indices.breaker.BreakerSettings;
|
||||
import org.opensearch.indices.breaker.HierarchyCircuitBreakerService;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import static org.hamcrest.Matchers.equalTo;
|
||||
|
|
|
@ -22,11 +22,11 @@ package org.opensearch.indices.recovery;
|
|||
import org.opensearch.cluster.service.ClusterService;
|
||||
import org.opensearch.common.settings.ClusterSettings;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.elasticsearch.index.seqno.SequenceNumbers;
|
||||
import org.elasticsearch.index.shard.IndexShard;
|
||||
import org.opensearch.index.seqno.SequenceNumbers;
|
||||
import org.opensearch.index.shard.IndexShard;
|
||||
import org.opensearch.index.shard.IndexShardTestCase;
|
||||
import org.elasticsearch.index.store.Store;
|
||||
import org.elasticsearch.indices.IndicesService;
|
||||
import org.opensearch.index.store.Store;
|
||||
import org.opensearch.indices.IndicesService;
|
||||
import org.opensearch.test.NodeRoles;
|
||||
import org.opensearch.transport.TransportService;
|
||||
|
||||
|
|
|
@ -36,15 +36,15 @@ import org.opensearch.common.bytes.BytesArray;
|
|||
import org.opensearch.common.settings.Settings;
|
||||
import org.opensearch.common.xcontent.XContentType;
|
||||
import org.opensearch.core.internal.io.IOUtils;
|
||||
import org.elasticsearch.index.engine.NoOpEngine;
|
||||
import org.elasticsearch.index.mapper.SourceToParse;
|
||||
import org.elasticsearch.index.seqno.SeqNoStats;
|
||||
import org.elasticsearch.index.seqno.SequenceNumbers;
|
||||
import org.elasticsearch.index.shard.IndexShard;
|
||||
import org.opensearch.index.engine.NoOpEngine;
|
||||
import org.opensearch.index.mapper.SourceToParse;
|
||||
import org.opensearch.index.seqno.SeqNoStats;
|
||||
import org.opensearch.index.seqno.SequenceNumbers;
|
||||
import org.opensearch.index.shard.IndexShard;
|
||||
import org.opensearch.index.shard.IndexShardTestCase;
|
||||
import org.elasticsearch.index.store.Store;
|
||||
import org.elasticsearch.index.store.StoreFileMetadata;
|
||||
import org.elasticsearch.index.translog.Translog;
|
||||
import org.opensearch.index.store.Store;
|
||||
import org.opensearch.index.store.StoreFileMetadata;
|
||||
import org.opensearch.index.translog.Translog;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.ArrayList;
|
||||
|
@ -57,7 +57,7 @@ import java.util.concurrent.CyclicBarrier;
|
|||
import java.util.stream.Collectors;
|
||||
import java.util.stream.LongStream;
|
||||
|
||||
import static org.elasticsearch.index.seqno.SequenceNumbers.UNASSIGNED_SEQ_NO;
|
||||
import static org.opensearch.index.seqno.SequenceNumbers.UNASSIGNED_SEQ_NO;
|
||||
import static org.hamcrest.Matchers.empty;
|
||||
import static org.hamcrest.Matchers.equalTo;
|
||||
import static org.hamcrest.Matchers.sameInstance;
|
||||
|
|
|
@ -22,7 +22,7 @@ package org.opensearch.indices.recovery;
|
|||
import org.opensearch.common.settings.ClusterSettings;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.opensearch.common.unit.TimeValue;
|
||||
import org.elasticsearch.indices.recovery.RecoverySettings;
|
||||
import org.opensearch.indices.recovery.RecoverySettings;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import java.util.concurrent.TimeUnit;
|
||||
|
|
|
@ -78,11 +78,11 @@ import org.opensearch.index.shard.ShardId;
|
|||
import org.opensearch.index.store.Store;
|
||||
import org.opensearch.index.store.StoreFileMetadata;
|
||||
import org.opensearch.index.translog.Translog;
|
||||
import org.elasticsearch.test.CorruptionUtils;
|
||||
import org.elasticsearch.test.DummyShardLock;
|
||||
import org.elasticsearch.test.ESTestCase;
|
||||
import org.elasticsearch.test.IndexSettingsModule;
|
||||
import org.elasticsearch.test.VersionUtils;
|
||||
import org.opensearch.test.CorruptionUtils;
|
||||
import org.opensearch.test.DummyShardLock;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.opensearch.test.IndexSettingsModule;
|
||||
import org.opensearch.test.VersionUtils;
|
||||
import org.opensearch.indices.recovery.AsyncRecoveryTarget;
|
||||
import org.opensearch.threadpool.FixedExecutorBuilder;
|
||||
import org.opensearch.threadpool.TestThreadPool;
|
||||
|
|
|
@ -21,9 +21,9 @@ package org.opensearch.indices.recovery;
|
|||
import org.apache.lucene.codecs.CodecUtil;
|
||||
import org.apache.lucene.store.IndexOutput;
|
||||
import org.opensearch.common.util.set.Sets;
|
||||
import org.elasticsearch.index.IndexService;
|
||||
import org.elasticsearch.index.shard.IndexShard;
|
||||
import org.elasticsearch.index.store.StoreFileMetadata;
|
||||
import org.opensearch.index.IndexService;
|
||||
import org.opensearch.index.shard.IndexShard;
|
||||
import org.opensearch.index.store.StoreFileMetadata;
|
||||
import org.opensearch.test.OpenSearchSingleNodeTestCase;
|
||||
|
||||
import java.io.IOException;
|
||||
|
|
|
@ -27,13 +27,13 @@ import org.opensearch.cluster.routing.TestShardRouting;
|
|||
import org.opensearch.common.io.stream.BytesStreamOutput;
|
||||
import org.opensearch.common.io.stream.StreamInput;
|
||||
import org.opensearch.common.io.stream.Writeable;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.elasticsearch.indices.recovery.RecoveryState.FileDetail;
|
||||
import org.elasticsearch.indices.recovery.RecoveryState.Index;
|
||||
import org.elasticsearch.indices.recovery.RecoveryState.Stage;
|
||||
import org.elasticsearch.indices.recovery.RecoveryState.Timer;
|
||||
import org.elasticsearch.indices.recovery.RecoveryState.Translog;
|
||||
import org.elasticsearch.indices.recovery.RecoveryState.VerifyIndex;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.indices.recovery.RecoveryState.FileDetail;
|
||||
import org.opensearch.indices.recovery.RecoveryState.Index;
|
||||
import org.opensearch.indices.recovery.RecoveryState.Stage;
|
||||
import org.opensearch.indices.recovery.RecoveryState.Timer;
|
||||
import org.opensearch.indices.recovery.RecoveryState.Translog;
|
||||
import org.opensearch.indices.recovery.RecoveryState.VerifyIndex;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import java.io.IOException;
|
||||
|
|
|
@ -24,10 +24,10 @@ import org.opensearch.cluster.node.DiscoveryNode;
|
|||
import org.opensearch.common.UUIDs;
|
||||
import org.opensearch.common.io.stream.InputStreamStreamInput;
|
||||
import org.opensearch.common.io.stream.OutputStreamStreamOutput;
|
||||
import org.elasticsearch.index.engine.Engine;
|
||||
import org.elasticsearch.index.seqno.SequenceNumbers;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.elasticsearch.index.store.Store;
|
||||
import org.opensearch.index.engine.Engine;
|
||||
import org.opensearch.index.seqno.SequenceNumbers;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.index.store.Store;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import java.io.ByteArrayInputStream;
|
||||
|
|
|
@ -25,7 +25,7 @@ import org.opensearch.cluster.routing.IndexShardRoutingTable;
|
|||
import org.opensearch.cluster.routing.ShardRoutingState;
|
||||
import org.opensearch.cluster.routing.TestShardRouting;
|
||||
import org.opensearch.cluster.routing.UnassignedInfo;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.junit.Before;
|
||||
|
||||
|
|
|
@ -50,8 +50,8 @@ import java.util.concurrent.TimeUnit;
|
|||
import java.util.concurrent.atomic.AtomicBoolean;
|
||||
import java.util.concurrent.atomic.AtomicInteger;
|
||||
|
||||
import static org.elasticsearch.monitor.StatusInfo.Status.HEALTHY;
|
||||
import static org.elasticsearch.monitor.StatusInfo.Status.UNHEALTHY;
|
||||
import static org.opensearch.monitor.StatusInfo.Status.HEALTHY;
|
||||
import static org.opensearch.monitor.StatusInfo.Status.UNHEALTHY;
|
||||
import static org.opensearch.node.Node.NODE_NAME_SETTING;
|
||||
import static org.hamcrest.Matchers.is;
|
||||
|
||||
|
@ -126,7 +126,7 @@ public class FsHealthServiceTests extends OpenSearchTestCase {
|
|||
}
|
||||
}
|
||||
|
||||
@TestLogging(value = "org.elasticsearch.monitor.fs:WARN", reason = "to ensure that we log on hung IO at WARN level")
|
||||
@TestLogging(value = "org.opensearch.monitor.fs:WARN", reason = "to ensure that we log on hung IO at WARN level")
|
||||
public void testLoggingOnHungIO() throws Exception {
|
||||
long slowLogThreshold = randomLongBetween(100, 200);
|
||||
final Settings settings = Settings.builder().put(FsHealthService.SLOW_PATH_LOGGING_THRESHOLD_SETTING.getKey(),
|
||||
|
|
|
@ -21,8 +21,8 @@ package org.opensearch.monitor.fs;
|
|||
|
||||
import org.apache.lucene.util.Constants;
|
||||
import org.opensearch.common.collect.Tuple;
|
||||
import org.elasticsearch.env.NodeEnvironment;
|
||||
import org.elasticsearch.env.NodeEnvironment.NodePath;
|
||||
import org.opensearch.env.NodeEnvironment;
|
||||
import org.opensearch.env.NodeEnvironment.NodePath;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import java.io.IOException;
|
||||
|
|
|
@ -23,7 +23,7 @@ import org.apache.lucene.util.Constants;
|
|||
import org.opensearch.bootstrap.BootstrapInfo;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import static org.elasticsearch.monitor.jvm.JvmInfo.jvmInfo;
|
||||
import static org.opensearch.monitor.jvm.JvmInfo.jvmInfo;
|
||||
import static org.hamcrest.Matchers.allOf;
|
||||
import static org.hamcrest.Matchers.anyOf;
|
||||
import static org.hamcrest.Matchers.equalTo;
|
||||
|
|
|
@ -27,13 +27,13 @@ import org.opensearch.common.breaker.CircuitBreaker;
|
|||
import org.opensearch.common.network.NetworkModule;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.opensearch.common.transport.BoundTransportAddress;
|
||||
import org.elasticsearch.env.Environment;
|
||||
import org.elasticsearch.index.IndexService;
|
||||
import org.elasticsearch.index.engine.Engine.Searcher;
|
||||
import org.elasticsearch.index.shard.IndexShard;
|
||||
import org.elasticsearch.indices.IndicesService;
|
||||
import org.elasticsearch.indices.breaker.BreakerSettings;
|
||||
import org.elasticsearch.indices.breaker.CircuitBreakerService;
|
||||
import org.opensearch.env.Environment;
|
||||
import org.opensearch.index.IndexService;
|
||||
import org.opensearch.index.engine.Engine.Searcher;
|
||||
import org.opensearch.index.shard.IndexShard;
|
||||
import org.opensearch.indices.IndicesService;
|
||||
import org.opensearch.indices.breaker.BreakerSettings;
|
||||
import org.opensearch.indices.breaker.CircuitBreakerService;
|
||||
import org.opensearch.plugins.CircuitBreakerPlugin;
|
||||
import org.opensearch.plugins.Plugin;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
|
|
@ -119,11 +119,11 @@ public class IndexStorePluginTests extends OpenSearchTestCase {
|
|||
if (JavaVersion.current().compareTo(JavaVersion.parse("9")) >= 0) {
|
||||
assertThat(e, hasToString(matches(
|
||||
"java.lang.IllegalStateException: Duplicate key store \\(attempted merging values " +
|
||||
"org.elasticsearch.index.store.FsDirectoryFactory@[\\w\\d]+ " +
|
||||
"and org.elasticsearch.index.store.FsDirectoryFactory@[\\w\\d]+\\)")));
|
||||
"org.opensearch.index.store.FsDirectoryFactory@[\\w\\d]+ " +
|
||||
"and org.opensearch.index.store.FsDirectoryFactory@[\\w\\d]+\\)")));
|
||||
} else {
|
||||
assertThat(e, hasToString(matches(
|
||||
"java.lang.IllegalStateException: Duplicate key org.elasticsearch.index.store.FsDirectoryFactory@[\\w\\d]+")));
|
||||
"java.lang.IllegalStateException: Duplicate key org.opensearch.index.store.FsDirectoryFactory@[\\w\\d]+")));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -22,9 +22,9 @@ import org.opensearch.OpenSearchException;
|
|||
import org.opensearch.cluster.node.DiscoveryNode;
|
||||
import org.opensearch.common.unit.TimeValue;
|
||||
import org.opensearch.index.replication.OpenSearchIndexLevelReplicationTestCase;
|
||||
import org.elasticsearch.index.shard.IndexShard;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.elasticsearch.index.store.Store;
|
||||
import org.opensearch.index.shard.IndexShard;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.index.store.Store;
|
||||
import org.opensearch.indices.recovery.RecoveriesCollection;
|
||||
import org.opensearch.indices.recovery.RecoveryFailedException;
|
||||
import org.opensearch.indices.recovery.RecoveryState;
|
||||
|
|
|
@ -22,8 +22,8 @@ package org.opensearch.repositories;
|
|||
import org.opensearch.cluster.service.ClusterService;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.opensearch.common.xcontent.NamedXContentRegistry;
|
||||
import org.elasticsearch.env.Environment;
|
||||
import org.elasticsearch.indices.recovery.RecoverySettings;
|
||||
import org.opensearch.env.Environment;
|
||||
import org.opensearch.indices.recovery.RecoverySettings;
|
||||
import org.opensearch.plugins.RepositoryPlugin;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.opensearch.threadpool.ThreadPool;
|
||||
|
|
|
@ -42,12 +42,12 @@ import org.opensearch.common.component.Lifecycle;
|
|||
import org.opensearch.common.component.LifecycleListener;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.opensearch.common.xcontent.NamedXContentRegistry;
|
||||
import org.elasticsearch.index.mapper.MapperService;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.elasticsearch.index.snapshots.IndexShardSnapshotStatus;
|
||||
import org.elasticsearch.index.store.Store;
|
||||
import org.elasticsearch.indices.recovery.RecoverySettings;
|
||||
import org.elasticsearch.indices.recovery.RecoveryState;
|
||||
import org.opensearch.index.mapper.MapperService;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.index.snapshots.IndexShardSnapshotStatus;
|
||||
import org.opensearch.index.store.Store;
|
||||
import org.opensearch.indices.recovery.RecoverySettings;
|
||||
import org.opensearch.indices.recovery.RecoveryState;
|
||||
import org.opensearch.repositories.blobstore.MeteredBlobStoreRepository;
|
||||
import org.opensearch.snapshots.SnapshotId;
|
||||
import org.opensearch.snapshots.SnapshotInfo;
|
||||
|
@ -84,7 +84,7 @@ public class RepositoriesServiceTests extends OpenSearchTestCase {
|
|||
final ClusterService clusterService = mock(ClusterService.class);
|
||||
when(clusterService.getClusterApplierService()).thenReturn(clusterApplierService);
|
||||
Map<String, Repository.Factory> typesRegistry =
|
||||
org.elasticsearch.common.collect.Map.of(TestRepository.TYPE, TestRepository::new,
|
||||
org.opensearch.common.collect.Map.of(TestRepository.TYPE, TestRepository::new,
|
||||
MeteredRepositoryTypeA.TYPE, metadata -> new MeteredRepositoryTypeA(metadata, clusterService),
|
||||
MeteredRepositoryTypeB.TYPE, metadata -> new MeteredRepositoryTypeB(metadata, clusterService));
|
||||
repositoriesService = new RepositoriesService(Settings.EMPTY, mock(ClusterService.class),
|
||||
|
@ -331,7 +331,7 @@ public class RepositoriesServiceTests extends OpenSearchTestCase {
|
|||
|
||||
private static class MeteredRepositoryTypeA extends MeteredBlobStoreRepository {
|
||||
private static final String TYPE = "type-a";
|
||||
private static final RepositoryStats STATS = new RepositoryStats(org.elasticsearch.common.collect.Map.of("GET", 10L));
|
||||
private static final RepositoryStats STATS = new RepositoryStats(org.opensearch.common.collect.Map.of("GET", 10L));
|
||||
|
||||
private MeteredRepositoryTypeA(RepositoryMetadata metadata, ClusterService clusterService) {
|
||||
super(metadata,
|
||||
|
@ -339,7 +339,7 @@ public class RepositoriesServiceTests extends OpenSearchTestCase {
|
|||
mock(NamedXContentRegistry.class),
|
||||
clusterService,
|
||||
mock(RecoverySettings.class),
|
||||
org.elasticsearch.common.collect.Map.of("bucket", "bucket-a"));
|
||||
org.opensearch.common.collect.Map.of("bucket", "bucket-a"));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -360,7 +360,7 @@ public class RepositoriesServiceTests extends OpenSearchTestCase {
|
|||
|
||||
private static class MeteredRepositoryTypeB extends MeteredBlobStoreRepository {
|
||||
private static final String TYPE = "type-b";
|
||||
private static final RepositoryStats STATS = new RepositoryStats(org.elasticsearch.common.collect.Map.of("LIST", 20L));
|
||||
private static final RepositoryStats STATS = new RepositoryStats(org.opensearch.common.collect.Map.of("LIST", 20L));
|
||||
|
||||
private MeteredRepositoryTypeB(RepositoryMetadata metadata, ClusterService clusterService) {
|
||||
super(metadata,
|
||||
|
@ -368,7 +368,7 @@ public class RepositoriesServiceTests extends OpenSearchTestCase {
|
|||
mock(NamedXContentRegistry.class),
|
||||
clusterService,
|
||||
mock(RecoverySettings.class),
|
||||
org.elasticsearch.common.collect.Map.of("bucket", "bucket-b"));
|
||||
org.opensearch.common.collect.Map.of("bucket", "bucket-b"));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -33,18 +33,18 @@ import org.opensearch.common.UUIDs;
|
|||
import org.opensearch.common.settings.ClusterSettings;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.opensearch.core.internal.io.IOUtils;
|
||||
import org.elasticsearch.env.Environment;
|
||||
import org.opensearch.env.Environment;
|
||||
import org.opensearch.env.TestEnvironment;
|
||||
import org.elasticsearch.index.engine.InternalEngineFactory;
|
||||
import org.elasticsearch.index.seqno.RetentionLeaseSyncer;
|
||||
import org.elasticsearch.index.shard.IndexShard;
|
||||
import org.elasticsearch.index.shard.IndexShardState;
|
||||
import org.opensearch.index.engine.InternalEngineFactory;
|
||||
import org.opensearch.index.seqno.RetentionLeaseSyncer;
|
||||
import org.opensearch.index.shard.IndexShard;
|
||||
import org.opensearch.index.shard.IndexShardState;
|
||||
import org.opensearch.index.shard.IndexShardTestCase;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.elasticsearch.index.snapshots.IndexShardSnapshotFailedException;
|
||||
import org.elasticsearch.index.store.Store;
|
||||
import org.elasticsearch.index.store.StoreFileMetadata;
|
||||
import org.elasticsearch.indices.recovery.RecoverySettings;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.index.snapshots.IndexShardSnapshotFailedException;
|
||||
import org.opensearch.index.store.Store;
|
||||
import org.opensearch.index.store.StoreFileMetadata;
|
||||
import org.opensearch.indices.recovery.RecoverySettings;
|
||||
import org.opensearch.repositories.IndexId;
|
||||
import org.opensearch.repositories.Repository;
|
||||
import org.opensearch.repositories.RepositoryData;
|
||||
|
|
|
@ -30,7 +30,7 @@ import org.opensearch.common.UUIDs;
|
|||
import org.opensearch.common.settings.Settings;
|
||||
import org.opensearch.common.unit.ByteSizeUnit;
|
||||
import org.opensearch.common.xcontent.NamedXContentRegistry;
|
||||
import org.elasticsearch.env.Environment;
|
||||
import org.opensearch.env.Environment;
|
||||
import org.opensearch.indices.recovery.RecoverySettings;
|
||||
import org.opensearch.plugins.Plugin;
|
||||
import org.opensearch.plugins.RepositoryPlugin;
|
||||
|
|
|
@ -39,7 +39,7 @@ import org.opensearch.http.HttpRequest;
|
|||
import org.opensearch.http.HttpResponse;
|
||||
import org.opensearch.http.HttpServerTransport;
|
||||
import org.opensearch.http.HttpStats;
|
||||
import org.elasticsearch.indices.breaker.HierarchyCircuitBreakerService;
|
||||
import org.opensearch.indices.breaker.HierarchyCircuitBreakerService;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.opensearch.test.client.NoOpNodeClient;
|
||||
import org.opensearch.test.rest.FakeRestRequest;
|
||||
|
|
|
@ -32,10 +32,10 @@ import org.opensearch.common.xcontent.ToXContent;
|
|||
import org.opensearch.common.xcontent.XContentBuilder;
|
||||
import org.opensearch.common.xcontent.XContentParser;
|
||||
import org.opensearch.common.xcontent.json.JsonXContent;
|
||||
import org.elasticsearch.index.Index;
|
||||
import org.elasticsearch.index.query.MatchQueryBuilder;
|
||||
import org.elasticsearch.index.query.QueryBuilder;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.opensearch.index.Index;
|
||||
import org.opensearch.index.query.MatchQueryBuilder;
|
||||
import org.opensearch.index.query.QueryBuilder;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.search.SearchModule;
|
||||
import org.opensearch.search.SearchShardTarget;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
|
|
@ -24,7 +24,7 @@ import org.opensearch.common.bytes.BytesArray;
|
|||
import org.opensearch.common.xcontent.XContentFactory;
|
||||
import org.opensearch.common.xcontent.XContentParser;
|
||||
import org.opensearch.common.xcontent.XContentType;
|
||||
import org.elasticsearch.index.analysis.NameOrDefinition;
|
||||
import org.opensearch.index.analysis.NameOrDefinition;
|
||||
import org.opensearch.rest.RestRequest;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.opensearch.test.client.NoOpNodeClient;
|
||||
|
|
|
@ -31,9 +31,9 @@ import org.opensearch.cluster.routing.TestShardRouting;
|
|||
import org.opensearch.common.Table;
|
||||
import org.opensearch.common.UUIDs;
|
||||
import org.opensearch.common.settings.Settings;
|
||||
import org.elasticsearch.index.Index;
|
||||
import org.elasticsearch.index.IndexSettings;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.opensearch.index.Index;
|
||||
import org.opensearch.index.IndexSettings;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.opensearch.test.rest.FakeRestRequest;
|
||||
|
||||
|
|
|
@ -29,9 +29,9 @@ import org.opensearch.common.Randomness;
|
|||
import org.opensearch.common.Table;
|
||||
import org.opensearch.common.unit.TimeValue;
|
||||
import org.opensearch.common.xcontent.XContentOpenSearchExtension;
|
||||
import org.elasticsearch.index.Index;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.elasticsearch.indices.recovery.RecoveryState;
|
||||
import org.opensearch.index.Index;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.indices.recovery.RecoveryState;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
|
|
@ -33,7 +33,7 @@ import org.opensearch.cluster.routing.ShardRouting;
|
|||
import org.opensearch.cluster.routing.ShardRoutingState;
|
||||
import org.opensearch.cluster.routing.TestShardRouting;
|
||||
import org.opensearch.common.Table;
|
||||
import org.elasticsearch.index.shard.ShardPath;
|
||||
import org.opensearch.index.shard.ShardPath;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.opensearch.test.rest.FakeRestRequest;
|
||||
|
||||
|
|
|
@ -24,7 +24,7 @@ import org.opensearch.action.get.GetResponse;
|
|||
import org.opensearch.common.bytes.BytesArray;
|
||||
import org.opensearch.common.bytes.BytesReference;
|
||||
import org.opensearch.common.util.concurrent.ThreadContext;
|
||||
import org.elasticsearch.index.get.GetResult;
|
||||
import org.opensearch.index.get.GetResult;
|
||||
import org.opensearch.rest.RestRequest;
|
||||
import org.opensearch.rest.RestRequest.Method;
|
||||
import org.opensearch.rest.RestResponse;
|
||||
|
@ -40,7 +40,7 @@ import java.util.HashMap;
|
|||
import java.util.Map;
|
||||
|
||||
import static java.util.Collections.emptyMap;
|
||||
import static org.elasticsearch.index.seqno.SequenceNumbers.UNASSIGNED_SEQ_NO;
|
||||
import static org.opensearch.index.seqno.SequenceNumbers.UNASSIGNED_SEQ_NO;
|
||||
import static org.opensearch.rest.RestStatus.OK;
|
||||
import static org.hamcrest.Matchers.equalTo;
|
||||
|
||||
|
|
|
@ -23,7 +23,7 @@ import org.opensearch.action.ActionRequestValidationException;
|
|||
import org.opensearch.client.node.NodeClient;
|
||||
import org.opensearch.common.bytes.BytesArray;
|
||||
import org.opensearch.common.xcontent.XContentType;
|
||||
import org.elasticsearch.index.VersionType;
|
||||
import org.opensearch.index.VersionType;
|
||||
import org.opensearch.rest.RestRequest;
|
||||
import org.opensearch.rest.RestRequest.Method;
|
||||
import org.opensearch.test.rest.FakeRestRequest;
|
||||
|
|
|
@ -48,7 +48,7 @@ import static org.hamcrest.Matchers.equalTo;
|
|||
|
||||
public class JodaCompatibleZonedDateTimeTests extends OpenSearchTestCase {
|
||||
private static final Logger DEPRECATION_LOGGER =
|
||||
LogManager.getLogger("org.elasticsearch.deprecation.script.JodaCompatibleZonedDateTime");
|
||||
LogManager.getLogger("org.opensearch.deprecation.script.JodaCompatibleZonedDateTime");
|
||||
|
||||
// each call to get or getValue will be run with limited permissions, just as they are in scripts
|
||||
private static PermissionCollection NO_PERMISSIONS = new Permissions();
|
||||
|
|
|
@ -270,19 +270,19 @@ public class ScriptContextInfoTests extends OpenSearchTestCase {
|
|||
" \"name\": \"weight\"" +
|
||||
" }," +
|
||||
" {" +
|
||||
" \"type\": \"org.elasticsearch.index.similarity.ScriptedSimilarity$Query\"," +
|
||||
" \"type\": \"org.opensearch.index.similarity.ScriptedSimilarity$Query\"," +
|
||||
" \"name\": \"query\"" +
|
||||
" }," +
|
||||
" {" +
|
||||
" \"type\": \"org.elasticsearch.index.similarity.ScriptedSimilarity$Field\"," +
|
||||
" \"type\": \"org.opensearch.index.similarity.ScriptedSimilarity$Field\"," +
|
||||
" \"name\": \"field\"" +
|
||||
" }," +
|
||||
" {" +
|
||||
" \"type\": \"org.elasticsearch.index.similarity.ScriptedSimilarity$Term\"," +
|
||||
" \"type\": \"org.opensearch.index.similarity.ScriptedSimilarity$Term\"," +
|
||||
" \"name\": \"term\"" +
|
||||
" }," +
|
||||
" {" +
|
||||
" \"type\": \"org.elasticsearch.index.similarity.ScriptedSimilarity$Doc\"," +
|
||||
" \"type\": \"org.opensearch.index.similarity.ScriptedSimilarity$Doc\"," +
|
||||
" \"name\": \"doc\"" +
|
||||
" }" +
|
||||
" ]" +
|
||||
|
|
|
@ -32,7 +32,7 @@ import org.opensearch.common.settings.Settings;
|
|||
import org.opensearch.common.unit.TimeValue;
|
||||
import org.opensearch.common.xcontent.XContentFactory;
|
||||
import org.opensearch.common.xcontent.XContentType;
|
||||
import org.elasticsearch.env.Environment;
|
||||
import org.opensearch.env.Environment;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
import org.junit.Before;
|
||||
|
||||
|
|
|
@ -29,7 +29,7 @@ import org.opensearch.common.settings.Settings;
|
|||
import org.opensearch.common.xcontent.NamedXContentRegistry;
|
||||
import org.opensearch.common.xcontent.XContentBuilder;
|
||||
import org.opensearch.common.xcontent.XContentParser;
|
||||
import org.elasticsearch.indices.IndicesModule;
|
||||
import org.opensearch.indices.IndicesModule;
|
||||
import org.opensearch.plugins.Plugin;
|
||||
import org.opensearch.plugins.SearchPlugin;
|
||||
import org.opensearch.search.builder.SearchSourceBuilder;
|
||||
|
|
|
@ -37,19 +37,19 @@ import org.opensearch.common.unit.TimeValue;
|
|||
import org.opensearch.common.util.BigArrays;
|
||||
import org.opensearch.common.util.MockBigArrays;
|
||||
import org.opensearch.common.util.MockPageCacheRecycler;
|
||||
import org.elasticsearch.index.IndexService;
|
||||
import org.elasticsearch.index.IndexSettings;
|
||||
import org.elasticsearch.index.cache.IndexCache;
|
||||
import org.elasticsearch.index.cache.query.QueryCache;
|
||||
import org.elasticsearch.index.engine.Engine;
|
||||
import org.elasticsearch.index.mapper.MappedFieldType;
|
||||
import org.elasticsearch.index.mapper.MapperService;
|
||||
import org.elasticsearch.index.query.AbstractQueryBuilder;
|
||||
import org.elasticsearch.index.query.ParsedQuery;
|
||||
import org.elasticsearch.index.query.QueryShardContext;
|
||||
import org.elasticsearch.index.shard.IndexShard;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.elasticsearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.index.IndexService;
|
||||
import org.opensearch.index.IndexSettings;
|
||||
import org.opensearch.index.cache.IndexCache;
|
||||
import org.opensearch.index.cache.query.QueryCache;
|
||||
import org.opensearch.index.engine.Engine;
|
||||
import org.opensearch.index.mapper.MappedFieldType;
|
||||
import org.opensearch.index.mapper.MapperService;
|
||||
import org.opensearch.index.query.AbstractQueryBuilder;
|
||||
import org.opensearch.index.query.ParsedQuery;
|
||||
import org.opensearch.index.query.QueryShardContext;
|
||||
import org.opensearch.index.shard.IndexShard;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.search.internal.AliasFilter;
|
||||
import org.opensearch.search.internal.LegacyReaderContext;
|
||||
import org.opensearch.search.internal.ReaderContext;
|
||||
|
|
|
@ -28,7 +28,7 @@ import org.opensearch.common.io.stream.NamedWriteableRegistry.Entry;
|
|||
import org.opensearch.common.io.stream.StreamInput;
|
||||
import org.opensearch.common.network.InetAddresses;
|
||||
import org.opensearch.common.time.DateFormatter;
|
||||
import org.elasticsearch.index.mapper.DateFieldMapper.Resolution;
|
||||
import org.opensearch.index.mapper.DateFieldMapper.Resolution;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import java.time.ZoneOffset;
|
||||
|
|
|
@ -30,15 +30,15 @@ import org.apache.lucene.util.BytesRef;
|
|||
import org.apache.lucene.util.FixedBitSet;
|
||||
import org.opensearch.common.io.stream.BytesStreamOutput;
|
||||
import org.opensearch.common.io.stream.StreamInput;
|
||||
import org.elasticsearch.index.fielddata.AbstractBinaryDocValues;
|
||||
import org.elasticsearch.index.fielddata.AbstractNumericDocValues;
|
||||
import org.elasticsearch.index.fielddata.AbstractSortedDocValues;
|
||||
import org.elasticsearch.index.fielddata.AbstractSortedNumericDocValues;
|
||||
import org.elasticsearch.index.fielddata.AbstractSortedSetDocValues;
|
||||
import org.elasticsearch.index.fielddata.FieldData;
|
||||
import org.elasticsearch.index.fielddata.NumericDoubleValues;
|
||||
import org.elasticsearch.index.fielddata.SortedBinaryDocValues;
|
||||
import org.elasticsearch.index.fielddata.SortedNumericDoubleValues;
|
||||
import org.opensearch.index.fielddata.AbstractBinaryDocValues;
|
||||
import org.opensearch.index.fielddata.AbstractNumericDocValues;
|
||||
import org.opensearch.index.fielddata.AbstractSortedDocValues;
|
||||
import org.opensearch.index.fielddata.AbstractSortedNumericDocValues;
|
||||
import org.opensearch.index.fielddata.AbstractSortedSetDocValues;
|
||||
import org.opensearch.index.fielddata.FieldData;
|
||||
import org.opensearch.index.fielddata.NumericDoubleValues;
|
||||
import org.opensearch.index.fielddata.SortedBinaryDocValues;
|
||||
import org.opensearch.index.fielddata.SortedNumericDoubleValues;
|
||||
import org.opensearch.test.OpenSearchTestCase;
|
||||
|
||||
import java.io.IOException;
|
||||
|
|
|
@ -34,9 +34,9 @@ import org.opensearch.common.xcontent.XContentBuilder;
|
|||
import org.opensearch.common.xcontent.XContentParser;
|
||||
import org.opensearch.common.xcontent.XContentType;
|
||||
import org.opensearch.common.xcontent.json.JsonXContent;
|
||||
import org.elasticsearch.index.Index;
|
||||
import org.opensearch.index.Index;
|
||||
import org.opensearch.index.get.GetResultTests;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.search.SearchHit.NestedIdentity;
|
||||
import org.opensearch.search.fetch.subphase.highlight.HighlightField;
|
||||
import org.opensearch.search.fetch.subphase.highlight.HighlightFieldTests;
|
||||
|
|
|
@ -34,8 +34,8 @@ import org.opensearch.common.xcontent.XContentBuilder;
|
|||
import org.opensearch.common.xcontent.XContentParser;
|
||||
import org.opensearch.common.xcontent.XContentType;
|
||||
import org.opensearch.common.xcontent.json.JsonXContent;
|
||||
import org.elasticsearch.index.Index;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
import org.opensearch.index.Index;
|
||||
import org.opensearch.index.shard.ShardId;
|
||||
import org.opensearch.test.AbstractSerializingTestCase;
|
||||
|
||||
import java.io.IOException;
|
||||
|
|
|
@ -21,7 +21,7 @@ package org.opensearch.search.aggregations;
|
|||
|
||||
import org.opensearch.common.xcontent.XContentParser;
|
||||
import org.opensearch.common.xcontent.json.JsonXContent;
|
||||
import org.elasticsearch.index.IndexService;
|
||||
import org.opensearch.index.IndexService;
|
||||
import org.opensearch.search.internal.SearchContext;
|
||||
import org.opensearch.test.OpenSearchSingleNodeTestCase;
|
||||
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
|
||||
package org.opensearch.search.aggregations;
|
||||
|
||||
import org.elasticsearch.index.fielddata.ScriptDocValues;
|
||||
import org.opensearch.index.fielddata.ScriptDocValues;
|
||||
import org.opensearch.script.MockScriptPlugin;
|
||||
import org.opensearch.script.Script;
|
||||
import org.opensearch.script.ScriptType;
|
||||
|
|
|
@ -31,12 +31,12 @@ import org.opensearch.common.xcontent.XContentFactory;
|
|||
import org.opensearch.common.xcontent.XContentParser;
|
||||
import org.opensearch.common.xcontent.XContentType;
|
||||
import org.opensearch.common.xcontent.json.JsonXContent;
|
||||
import org.elasticsearch.env.Environment;
|
||||
import org.elasticsearch.index.query.MatchAllQueryBuilder;
|
||||
import org.elasticsearch.index.query.QueryBuilder;
|
||||
import org.elasticsearch.index.query.QueryRewriteContext;
|
||||
import org.elasticsearch.index.query.TermsQueryBuilder;
|
||||
import org.elasticsearch.index.query.WrapperQueryBuilder;
|
||||
import org.opensearch.env.Environment;
|
||||
import org.opensearch.index.query.MatchAllQueryBuilder;
|
||||
import org.opensearch.index.query.QueryBuilder;
|
||||
import org.opensearch.index.query.QueryRewriteContext;
|
||||
import org.opensearch.index.query.TermsQueryBuilder;
|
||||
import org.opensearch.index.query.WrapperQueryBuilder;
|
||||
import org.opensearch.script.Script;
|
||||
import org.opensearch.search.SearchModule;
|
||||
import org.opensearch.search.aggregations.bucket.filter.FilterAggregationBuilder;
|
||||
|
|
|
@ -28,8 +28,8 @@ import org.apache.lucene.index.RandomIndexWriter;
|
|||
import org.apache.lucene.search.IndexSearcher;
|
||||
import org.apache.lucene.store.Directory;
|
||||
import org.opensearch.common.breaker.CircuitBreaker;
|
||||
import org.elasticsearch.index.mapper.NumberFieldMapper;
|
||||
import org.elasticsearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.index.mapper.NumberFieldMapper;
|
||||
import org.opensearch.indices.breaker.NoneCircuitBreakerService;
|
||||
import org.opensearch.search.aggregations.AggregatorFactories;
|
||||
import org.opensearch.search.aggregations.AggregatorTestCase;
|
||||
import org.opensearch.search.aggregations.InternalAggregation;
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
|
||||
package org.opensearch.search.aggregations.bucket;
|
||||
|
||||
import org.elasticsearch.index.query.QueryBuilders;
|
||||
import org.opensearch.index.query.QueryBuilders;
|
||||
import org.opensearch.search.aggregations.BaseAggregationTestCase;
|
||||
import org.opensearch.search.aggregations.bucket.filter.FilterAggregationBuilder;
|
||||
|
||||
|
|
|
@ -23,12 +23,12 @@ import org.opensearch.common.xcontent.XContentBuilder;
|
|||
import org.opensearch.common.xcontent.XContentFactory;
|
||||
import org.opensearch.common.xcontent.XContentParser;
|
||||
import org.opensearch.common.xcontent.XContentType;
|
||||
import org.elasticsearch.index.query.BoolQueryBuilder;
|
||||
import org.elasticsearch.index.query.MatchAllQueryBuilder;
|
||||
import org.elasticsearch.index.query.MatchNoneQueryBuilder;
|
||||
import org.elasticsearch.index.query.QueryBuilder;
|
||||
import org.elasticsearch.index.query.QueryBuilders;
|
||||
import org.elasticsearch.index.query.QueryRewriteContext;
|
||||
import org.opensearch.index.query.BoolQueryBuilder;
|
||||
import org.opensearch.index.query.MatchAllQueryBuilder;
|
||||
import org.opensearch.index.query.MatchNoneQueryBuilder;
|
||||
import org.opensearch.index.query.QueryBuilder;
|
||||
import org.opensearch.index.query.QueryBuilders;
|
||||
import org.opensearch.index.query.QueryRewriteContext;
|
||||
import org.opensearch.search.aggregations.AggregationBuilder;
|
||||
import org.opensearch.search.aggregations.BaseAggregationTestCase;
|
||||
import org.opensearch.search.aggregations.bucket.filter.FiltersAggregationBuilder;
|
||||
|
|
|
@ -27,8 +27,8 @@ import org.apache.lucene.search.IndexSearcher;
|
|||
import org.apache.lucene.search.MatchAllDocsQuery;
|
||||
import org.apache.lucene.store.Directory;
|
||||
import org.opensearch.common.CheckedConsumer;
|
||||
import org.elasticsearch.index.mapper.MappedFieldType;
|
||||
import org.elasticsearch.index.mapper.NumberFieldMapper;
|
||||
import org.opensearch.index.mapper.MappedFieldType;
|
||||
import org.opensearch.index.mapper.NumberFieldMapper;
|
||||
import org.opensearch.search.aggregations.AggregatorTestCase;
|
||||
import org.opensearch.search.aggregations.bucket.global.GlobalAggregationBuilder;
|
||||
import org.opensearch.search.aggregations.bucket.global.GlobalAggregator;
|
||||
|
|
|
@ -61,13 +61,13 @@ public class MergingBucketsDeferringCollectorTests extends AggregatorTestCase {
|
|||
deferringCollector.prepareSelectedBuckets(0, 8, 9);
|
||||
|
||||
equalTo(
|
||||
org.elasticsearch.common.collect.Map.of(
|
||||
org.opensearch.common.collect.Map.of(
|
||||
0L,
|
||||
org.elasticsearch.common.collect.List.of(0, 1, 2, 3, 4, 5, 6, 7),
|
||||
org.opensearch.common.collect.List.of(0, 1, 2, 3, 4, 5, 6, 7),
|
||||
1L,
|
||||
org.elasticsearch.common.collect.List.of(8),
|
||||
org.opensearch.common.collect.List.of(8),
|
||||
2L,
|
||||
org.elasticsearch.common.collect.List.of(9)
|
||||
org.opensearch.common.collect.List.of(9)
|
||||
)
|
||||
);
|
||||
});
|
||||
|
@ -89,13 +89,13 @@ public class MergingBucketsDeferringCollectorTests extends AggregatorTestCase {
|
|||
assertThat(
|
||||
finalCollector.collection,
|
||||
equalTo(
|
||||
org.elasticsearch.common.collect.Map.of(
|
||||
org.opensearch.common.collect.Map.of(
|
||||
0L,
|
||||
org.elasticsearch.common.collect.List.of(4, 5, 6, 7),
|
||||
org.opensearch.common.collect.List.of(4, 5, 6, 7),
|
||||
1L,
|
||||
org.elasticsearch.common.collect.List.of(8),
|
||||
org.opensearch.common.collect.List.of(8),
|
||||
2L,
|
||||
org.elasticsearch.common.collect.List.of(9)
|
||||
org.opensearch.common.collect.List.of(9)
|
||||
)
|
||||
)
|
||||
);
|
||||
|
@ -119,13 +119,13 @@ public class MergingBucketsDeferringCollectorTests extends AggregatorTestCase {
|
|||
assertThat(
|
||||
finalCollector.collection,
|
||||
equalTo(
|
||||
org.elasticsearch.common.collect.Map.of(
|
||||
org.opensearch.common.collect.Map.of(
|
||||
0L,
|
||||
org.elasticsearch.common.collect.List.of(0, 1, 2, 3),
|
||||
org.opensearch.common.collect.List.of(0, 1, 2, 3),
|
||||
1L,
|
||||
org.elasticsearch.common.collect.List.of(8),
|
||||
org.opensearch.common.collect.List.of(8),
|
||||
2L,
|
||||
org.elasticsearch.common.collect.List.of(9)
|
||||
org.opensearch.common.collect.List.of(9)
|
||||
)
|
||||
)
|
||||
);
|
||||
|
|
|
@ -21,7 +21,7 @@ package org.opensearch.search.aggregations.bucket;
|
|||
|
||||
import org.apache.lucene.util.BytesRef;
|
||||
import org.apache.lucene.util.automaton.RegExp;
|
||||
import org.elasticsearch.index.query.QueryBuilders;
|
||||
import org.opensearch.index.query.QueryBuilders;
|
||||
import org.opensearch.search.aggregations.BaseAggregationTestCase;
|
||||
import org.opensearch.search.aggregations.bucket.terms.IncludeExclude;
|
||||
import org.opensearch.search.aggregations.bucket.terms.SignificantTermsAggregationBuilder;
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
|
||||
package org.opensearch.search.aggregations.bucket;
|
||||
|
||||
import org.elasticsearch.index.query.QueryBuilders;
|
||||
import org.opensearch.index.query.QueryBuilders;
|
||||
import org.opensearch.search.aggregations.BaseAggregationTestCase;
|
||||
import org.opensearch.search.aggregations.bucket.terms.IncludeExclude;
|
||||
import org.opensearch.search.aggregations.bucket.terms.SignificantTextAggregationBuilder;
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue