From abf58504851665801fd8e730cb9754cf26ca3d48 Mon Sep 17 00:00:00 2001 From: Nicholas Knize Date: Tue, 2 Mar 2021 15:28:07 -0600 Subject: [PATCH] Revert "[Rename] server/src/main/java/org/apache (#162)" This reverts commit c50e8c83a2476ca4ca2f1dd05fa5a608bc0e9ef6 which went should have merged to the rename branch instead of the main branch. Signed-off-by: Peter Nied --- .../miscellaneous/DeDuplicatingTokenFilter.java | 16 ++++++++-------- .../lucene/index/ShuffleForcedMergePolicy.java | 2 +- .../queries/BinaryDocValuesRangeQuery.java | 2 +- .../lucene/queries/ExtendedCommonTermsQuery.java | 2 +- .../queries/SearchAfterSortedDocQuery.java | 2 +- .../search/grouping/CollapseTopFieldDocs.java | 2 +- .../grouping/CollapsingDocValuesSource.java | 6 +++--- .../grouping/CollapsingTopDocsCollector.java | 2 +- .../uhighlight/CustomPassageFormatter.java | 2 +- .../uhighlight/CustomUnifiedHighlighter.java | 8 ++++---- .../search/vectorhighlight/CustomFieldQuery.java | 6 +++--- 11 files changed, 25 insertions(+), 25 deletions(-) diff --git a/server/src/main/java/org/apache/lucene/analysis/miscellaneous/DeDuplicatingTokenFilter.java b/server/src/main/java/org/apache/lucene/analysis/miscellaneous/DeDuplicatingTokenFilter.java index 86e8dcadb5b33..3265ab8addce8 100644 --- a/server/src/main/java/org/apache/lucene/analysis/miscellaneous/DeDuplicatingTokenFilter.java +++ b/server/src/main/java/org/apache/lucene/analysis/miscellaneous/DeDuplicatingTokenFilter.java @@ -24,7 +24,7 @@ import org.apache.lucene.analysis.TokenStream; import org.apache.lucene.analysis.tokenattributes.TermToBytesRefAttribute; import org.apache.lucene.util.BytesRef; -import org.opensearch.common.hash.MurmurHash3; +import org.elasticsearch.common.hash.MurmurHash3; import java.io.IOException; import java.util.ArrayList; @@ -34,14 +34,14 @@ * have a minimum length - 6 is a good heuristic as it avoids filtering common * idioms/phrases but detects longer sections that are typical of cut+paste * copies of text. - * + * *

* Internally each token is hashed/moduloed into a single byte (so 256 possible * values for each token) and then recorded in a trie of seen byte sequences * using a {@link DuplicateByteSequenceSpotter}. This trie is passed into the * TokenFilter constructor so a single object can be reused across multiple * documents. - * + * *

* The emitDuplicates setting controls if duplicate tokens are filtered from * results or are output (the {@link DuplicateSequenceAttribute} attribute can @@ -57,7 +57,7 @@ public DeDuplicatingTokenFilter(TokenStream in, DuplicateByteSequenceSpotter byt } /** - * + * * @param in * The input token stream * @param byteStreamDuplicateSpotter @@ -110,9 +110,9 @@ public final boolean incrementToken() throws IOException { } public void loadAllTokens() throws IOException { - // TODO consider changing this implementation to emit tokens as-we-go - // rather than buffering all. However this array is perhaps not the - // bulk of memory usage (in practice the dupSequenceSpotter requires + // TODO consider changing this implementation to emit tokens as-we-go + // rather than buffering all. However this array is perhaps not the + // bulk of memory usage (in practice the dupSequenceSpotter requires // ~5x the original content size in its internal tree ). allTokens = new ArrayList(256); @@ -198,4 +198,4 @@ private void recordLengthInfoState(short[] maxNumSightings, State[] tokenStates, } } -} +} \ No newline at end of file diff --git a/server/src/main/java/org/apache/lucene/index/ShuffleForcedMergePolicy.java b/server/src/main/java/org/apache/lucene/index/ShuffleForcedMergePolicy.java index 277c35e40cc9f..b69523d83e724 100644 --- a/server/src/main/java/org/apache/lucene/index/ShuffleForcedMergePolicy.java +++ b/server/src/main/java/org/apache/lucene/index/ShuffleForcedMergePolicy.java @@ -19,7 +19,7 @@ package org.apache.lucene.index; -import org.opensearch.common.lucene.Lucene; +import org.elasticsearch.common.lucene.Lucene; import java.io.IOException; import java.util.ArrayList; diff --git a/server/src/main/java/org/apache/lucene/queries/BinaryDocValuesRangeQuery.java b/server/src/main/java/org/apache/lucene/queries/BinaryDocValuesRangeQuery.java index b7afe385f7582..0c3de3b7ed2b6 100644 --- a/server/src/main/java/org/apache/lucene/queries/BinaryDocValuesRangeQuery.java +++ b/server/src/main/java/org/apache/lucene/queries/BinaryDocValuesRangeQuery.java @@ -32,7 +32,7 @@ import org.apache.lucene.search.Weight; import org.apache.lucene.store.ByteArrayDataInput; import org.apache.lucene.util.BytesRef; -import org.opensearch.index.mapper.RangeType; +import org.elasticsearch.index.mapper.RangeType; import java.io.IOException; import java.util.Objects; diff --git a/server/src/main/java/org/apache/lucene/queries/ExtendedCommonTermsQuery.java b/server/src/main/java/org/apache/lucene/queries/ExtendedCommonTermsQuery.java index 94135754361c7..2d70ed8b90a05 100644 --- a/server/src/main/java/org/apache/lucene/queries/ExtendedCommonTermsQuery.java +++ b/server/src/main/java/org/apache/lucene/queries/ExtendedCommonTermsQuery.java @@ -20,7 +20,7 @@ package org.apache.lucene.queries; import org.apache.lucene.search.BooleanClause.Occur; -import org.opensearch.common.lucene.search.Queries; +import org.elasticsearch.common.lucene.search.Queries; /** * Extended version of {@link CommonTermsQuery} that allows to pass in a diff --git a/server/src/main/java/org/apache/lucene/queries/SearchAfterSortedDocQuery.java b/server/src/main/java/org/apache/lucene/queries/SearchAfterSortedDocQuery.java index c3a36507afcca..6497739c48cac 100644 --- a/server/src/main/java/org/apache/lucene/queries/SearchAfterSortedDocQuery.java +++ b/server/src/main/java/org/apache/lucene/queries/SearchAfterSortedDocQuery.java @@ -33,7 +33,7 @@ import org.apache.lucene.search.Sort; import org.apache.lucene.search.SortField; import org.apache.lucene.search.Weight; -import org.opensearch.common.lucene.Lucene; +import org.elasticsearch.common.lucene.Lucene; import java.io.IOException; import java.util.Arrays; diff --git a/server/src/main/java/org/apache/lucene/search/grouping/CollapseTopFieldDocs.java b/server/src/main/java/org/apache/lucene/search/grouping/CollapseTopFieldDocs.java index 00d3eed9c1d8c..9c0e6dfba914f 100644 --- a/server/src/main/java/org/apache/lucene/search/grouping/CollapseTopFieldDocs.java +++ b/server/src/main/java/org/apache/lucene/search/grouping/CollapseTopFieldDocs.java @@ -26,7 +26,7 @@ import org.apache.lucene.search.TopFieldDocs; import org.apache.lucene.search.TotalHits; import org.apache.lucene.util.PriorityQueue; -import org.opensearch.common.util.CollectionUtils; +import org.elasticsearch.common.util.CollectionUtils; import java.util.ArrayList; import java.util.HashSet; diff --git a/server/src/main/java/org/apache/lucene/search/grouping/CollapsingDocValuesSource.java b/server/src/main/java/org/apache/lucene/search/grouping/CollapsingDocValuesSource.java index 7f0391e517b74..a9da3b342fb4d 100644 --- a/server/src/main/java/org/apache/lucene/search/grouping/CollapsingDocValuesSource.java +++ b/server/src/main/java/org/apache/lucene/search/grouping/CollapsingDocValuesSource.java @@ -29,9 +29,9 @@ import org.apache.lucene.index.SortedSetDocValues; import org.apache.lucene.search.Scorable; import org.apache.lucene.util.BytesRef; -import org.opensearch.index.fielddata.AbstractNumericDocValues; -import org.opensearch.index.fielddata.AbstractSortedDocValues; -import org.opensearch.index.mapper.MappedFieldType; +import org.elasticsearch.index.fielddata.AbstractNumericDocValues; +import org.elasticsearch.index.fielddata.AbstractSortedDocValues; +import org.elasticsearch.index.mapper.MappedFieldType; import java.io.IOException; import java.util.Collection; diff --git a/server/src/main/java/org/apache/lucene/search/grouping/CollapsingTopDocsCollector.java b/server/src/main/java/org/apache/lucene/search/grouping/CollapsingTopDocsCollector.java index d5cccadb32040..90ed8773abd24 100644 --- a/server/src/main/java/org/apache/lucene/search/grouping/CollapsingTopDocsCollector.java +++ b/server/src/main/java/org/apache/lucene/search/grouping/CollapsingTopDocsCollector.java @@ -25,7 +25,7 @@ import org.apache.lucene.search.Sort; import org.apache.lucene.search.SortField; import org.apache.lucene.search.TotalHits; -import org.opensearch.index.mapper.MappedFieldType; +import org.elasticsearch.index.mapper.MappedFieldType; import java.io.IOException; import java.util.Collection; diff --git a/server/src/main/java/org/apache/lucene/search/uhighlight/CustomPassageFormatter.java b/server/src/main/java/org/apache/lucene/search/uhighlight/CustomPassageFormatter.java index 2ea925a974567..723c30f10dc61 100644 --- a/server/src/main/java/org/apache/lucene/search/uhighlight/CustomPassageFormatter.java +++ b/server/src/main/java/org/apache/lucene/search/uhighlight/CustomPassageFormatter.java @@ -20,7 +20,7 @@ package org.apache.lucene.search.uhighlight; import org.apache.lucene.search.highlight.Encoder; -import org.opensearch.search.fetch.subphase.highlight.HighlightUtils; +import org.elasticsearch.search.fetch.subphase.highlight.HighlightUtils; /** * Custom passage formatter that allows us to: diff --git a/server/src/main/java/org/apache/lucene/search/uhighlight/CustomUnifiedHighlighter.java b/server/src/main/java/org/apache/lucene/search/uhighlight/CustomUnifiedHighlighter.java index c3f92e91d5d75..3a2693a2d42cd 100644 --- a/server/src/main/java/org/apache/lucene/search/uhighlight/CustomUnifiedHighlighter.java +++ b/server/src/main/java/org/apache/lucene/search/uhighlight/CustomUnifiedHighlighter.java @@ -31,10 +31,10 @@ import org.apache.lucene.search.spans.SpanQuery; import org.apache.lucene.search.spans.SpanTermQuery; import org.apache.lucene.util.BytesRef; -import org.opensearch.common.CheckedSupplier; -import org.opensearch.common.Nullable; -import org.opensearch.common.lucene.search.MultiPhrasePrefixQuery; -import org.opensearch.index.IndexSettings; +import org.elasticsearch.common.CheckedSupplier; +import org.elasticsearch.common.Nullable; +import org.elasticsearch.common.lucene.search.MultiPhrasePrefixQuery; +import org.elasticsearch.index.IndexSettings; import java.io.IOException; import java.text.BreakIterator; diff --git a/server/src/main/java/org/apache/lucene/search/vectorhighlight/CustomFieldQuery.java b/server/src/main/java/org/apache/lucene/search/vectorhighlight/CustomFieldQuery.java index e55b144dc013c..a4791e85ef3ca 100644 --- a/server/src/main/java/org/apache/lucene/search/vectorhighlight/CustomFieldQuery.java +++ b/server/src/main/java/org/apache/lucene/search/vectorhighlight/CustomFieldQuery.java @@ -30,9 +30,9 @@ import org.apache.lucene.search.SynonymQuery; import org.apache.lucene.search.TermQuery; import org.apache.lucene.search.spans.SpanTermQuery; -import org.opensearch.common.lucene.search.MultiPhrasePrefixQuery; -import org.opensearch.common.lucene.search.function.FunctionScoreQuery; -import org.opensearch.index.search.ESToParentBlockJoinQuery; +import org.elasticsearch.common.lucene.search.MultiPhrasePrefixQuery; +import org.elasticsearch.common.lucene.search.function.FunctionScoreQuery; +import org.elasticsearch.index.search.ESToParentBlockJoinQuery; import java.io.IOException; import java.util.Collection;