Apache Solr open-source search software
SOLR-13952: reverting Erick's commit (with permission).
Dawid Weiss063c82ebd6c3
diff --git a/lucene/analysis/common/src/java/org/apache/lucene/analysis/miscellaneous/FixBrokenOffsetsFilterFactory.java b/lucene/analysis/common/src/java/org/apache/lucene/analysis/miscellaneous/FixBrokenOffsetsFilterFactory.javaindex 3ef9ebd676e..04503e42439 100644--- a/lucene/analysis/common/src/java/org/apache/lucene/analysis/miscellaneous/FixBrokenOffsetsFilterFactory.java+++ b/lucene/analysis/common/src/java/org/apache/lucene/analysis/miscellaneous/FixBrokenOffsetsFilterFactory.java@@ -37,7 +37,6 @@ public class FixBrokenOffsetsFilterFactory extends TokenFilterFactory {super(args);}- @SuppressWarnings("deprecation")@Overridepublic TokenStream create(TokenStream input) {return new FixBrokenOffsetsFilter(input);diff --git a/lucene/analysis/common/src/java/org/apache/lucene/analysis/miscellaneous/WordDelimiterFilterFactory.java b/lucene/analysis/common/src/java/org/apache/lucene/analysis/miscellaneous/WordDelimiterFilterFactory.javaindex 71ad6f90b1a..3cd13e4601d 100644--- a/lucene/analysis/common/src/java/org/apache/lucene/analysis/miscellaneous/WordDelimiterFilterFactory.java+++ b/lucene/analysis/common/src/java/org/apache/lucene/analysis/miscellaneous/WordDelimiterFilterFactory.java@@ -33,6 +33,8 @@ import org.apache.lucene.analysis.util.ResourceLoaderAware;import org.apache.lucene.analysis.util.TokenFilterFactory;import org.apache.lucene.search.PhraseQuery;+import static org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter.*;+/*** Factory for {@link WordDelimiterFilter}.* <pre class="prettyprint">@@ -74,31 +76,31 @@ public class WordDelimiterFilterFactory extends TokenFilterFactory implements Resuper(args);int flags = 0;if (getInt(args, "generateWordParts", 1) != 0) {- flags |= org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter.GENERATE_WORD_PARTS;+ flags |= GENERATE_WORD_PARTS;}if (getInt(args, "generateNumberParts", 1) != 0) {- flags |= org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter.GENERATE_NUMBER_PARTS;+ flags |= GENERATE_NUMBER_PARTS;}if (getInt(args, "catenateWords", 0) != 0) {- flags |= org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter.CATENATE_WORDS;+ flags |= CATENATE_WORDS;}if (getInt(args, "catenateNumbers", 0) != 0) {- flags |= org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter.CATENATE_NUMBERS;+ flags |= CATENATE_NUMBERS;}if (getInt(args, "catenateAll", 0) != 0) {- flags |= org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter.CATENATE_ALL;+ flags |= CATENATE_ALL;}if (getInt(args, "splitOnCaseChange", 1) != 0) {- flags |= org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter.SPLIT_ON_CASE_CHANGE;+ flags |= SPLIT_ON_CASE_CHANGE;}if (getInt(args, "splitOnNumerics", 1) != 0) {- flags |= org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter.SPLIT_ON_NUMERICS;+ flags |= SPLIT_ON_NUMERICS;}if (getInt(args, "preserveOriginal", 0) != 0) {- flags |= org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter.PRESERVE_ORIGINAL;+ flags |= PRESERVE_ORIGINAL;}if (getInt(args, "stemEnglishPossessive", 1) != 0) {- flags |= org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter.STEM_ENGLISH_POSSESSIVE;+ flags |= STEM_ENGLISH_POSSESSIVE;}wordFiles = get(args, PROTECTED_TOKENS);types = get(args, TYPES);@@ -160,17 +162,17 @@ public class WordDelimiterFilterFactory extends TokenFilterFactory implements Reprivate Byte parseType(String s) {if (s.equals("LOWER"))- return org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter.LOWER;+ return LOWER;else if (s.equals("UPPER"))- return org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter.UPPER;+ return UPPER;else if (s.equals("ALPHA"))- return org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter.ALPHA;+ return ALPHA;else if (s.equals("DIGIT"))- return org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter.DIGIT;+ return DIGIT;else if (s.equals("ALPHANUM"))- return org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter.ALPHANUM;+ return ALPHANUM;else if (s.equals("SUBWORD_DELIM"))- return org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter.SUBWORD_DELIM;+ return SUBWORD_DELIM;elsereturn null;}diff --git a/lucene/analysis/common/src/java/org/apache/lucene/analysis/synonym/SynonymMap.java b/lucene/analysis/common/src/java/org/apache/lucene/analysis/synonym/SynonymMap.javaindex c7df3239e0f..97db1deb3e4 100644--- a/lucene/analysis/common/src/java/org/apache/lucene/analysis/synonym/SynonymMap.java+++ b/lucene/analysis/common/src/java/org/apache/lucene/analysis/synonym/SynonymMap.java@@ -210,7 +210,6 @@ public class SynonymMap {/*** Builds an {@link SynonymMap} and returns it.*/- @SuppressWarnings("deprecation")public SynonymMap build() throws IOException {ByteSequenceOutputs outputs = ByteSequenceOutputs.getSingleton();// TODO: are we using the best sharing options?diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/ckb/TestSoraniStemFilterFactory.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/ckb/TestSoraniStemFilterFactory.javaindex c54a2b6cd75..1c4b1623c58 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/ckb/TestSoraniStemFilterFactory.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/ckb/TestSoraniStemFilterFactory.java@@ -30,7 +30,6 @@ import org.apache.lucene.analysis.util.BaseTokenStreamFactoryTestCase;*/public class TestSoraniStemFilterFactory extends BaseTokenStreamFactoryTestCase {- @SuppressWarnings("resource")public void testStemming() throws Exception {Reader reader = new StringReader("پیاوەکان");TokenStream stream = new MockTokenizer(MockTokenizer.WHITESPACE, false);diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/compound/da_UTF8.xml b/lucene/analysis/common/src/test/org/apache/lucene/analysis/compound/da_UTF8.xmlindex 06dfa8f5237..2c8d203be68 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/compound/da_UTF8.xml+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/compound/da_UTF8.xml@@ -1,22 +1,19 @@<?xml version="1.0" encoding="utf-8"?><!DOCTYPE hyphenation-info SYSTEM "hyphenation.dtd"><!--- Licensed to the Apache Software Foundation (ASF) under one- or more contributor license agreements. See the NOTICE file- distributed with this work for additional information- regarding copyright ownership. The ASF licenses this file- to you under the Apache License, Version 2.0 (the- "License"); you may not use this file except in compliance- with the License. You may obtain a copy of the License at+ Copyright 1999-2004 The Apache Software Foundation- http://www.apache.org/licenses/LICENSE-2.0+ Licensed under the Apache License, Version 2.0 (the "License");+ you may not use this file except in compliance with the License.+ You may obtain a copy of the License at- Unless required by applicable law or agreed to in writing,- software distributed under the License is distributed on an- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY- KIND, either express or implied. See the License for the- specific language governing permissions and limitations- under the License.+ http://www.apache.org/licenses/LICENSE-2.0++ Unless required by applicable law or agreed to in writing, software+ distributed under the License is distributed on an "AS IS" BASIS,+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.+ See the License for the specific language governing permissions and+ limitations under the License.--><!--This file contains the hyphenation patterns for danish.diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/compound/hyphenation-LUCENE-8124.xml b/lucene/analysis/common/src/test/org/apache/lucene/analysis/compound/hyphenation-LUCENE-8124.xmlindex 1c0572bfddb..8710eab0872 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/compound/hyphenation-LUCENE-8124.xml+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/compound/hyphenation-LUCENE-8124.xml@@ -1,22 +1,17 @@<?xml version="1.0" encoding="utf-8"?><!DOCTYPE hyphenation-info SYSTEM "hyphenation.dtd"><!--- Licensed to the Apache Software Foundation (ASF) under one- or more contributor license agreements. See the NOTICE file- distributed with this work for additional information- regarding copyright ownership. The ASF licenses this file- to you under the Apache License, Version 2.0 (the- "License"); you may not use this file except in compliance- with the License. You may obtain a copy of the License at+ Licensed under the Apache License, Version 2.0 (the "License");+ you may not use this file except in compliance with the License.+ You may obtain a copy of the License at- http://www.apache.org/licenses/LICENSE-2.0+ http://www.apache.org/licenses/LICENSE-2.0- Unless required by applicable law or agreed to in writing,- software distributed under the License is distributed on an- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY- KIND, either express or implied. See the License for the- specific language governing permissions and limitations- under the License.+ Unless required by applicable law or agreed to in writing, software+ distributed under the License is distributed on an "AS IS" BASIS,+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.+ See the License for the specific language governing permissions and+ limitations under the License.--><!--This file contains the hyphenation patterns for danish.diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/compound/hyphenation.dtd b/lucene/analysis/common/src/test/org/apache/lucene/analysis/compound/hyphenation.dtdindex 6da51d68958..fb3db16cf67 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/compound/hyphenation.dtd+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/compound/hyphenation.dtd@@ -1,21 +1,18 @@<?xml version="1.0" encoding="utf-8"?><!--- Licensed to the Apache Software Foundation (ASF) under one- or more contributor license agreements. See the NOTICE file- distributed with this work for additional information- regarding copyright ownership. The ASF licenses this file- to you under the Apache License, Version 2.0 (the- "License"); you may not use this file except in compliance- with the License. You may obtain a copy of the License at+ Copyright 1999-2004 The Apache Software Foundation- http://www.apache.org/licenses/LICENSE-2.0+ Licensed under the Apache License, Version 2.0 (the "License");+ you may not use this file except in compliance with the License.+ You may obtain a copy of the License at- Unless required by applicable law or agreed to in writing,- software distributed under the License is distributed on an- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY- KIND, either express or implied. See the License for the- specific language governing permissions and limitations- under the License.+ http://www.apache.org/licenses/LICENSE-2.0++ Unless required by applicable law or agreed to in writing, software+ distributed under the License is distributed on an "AS IS" BASIS,+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.+ See the License for the specific language governing permissions and+ limitations under the License.--><!-- Id: hyphenation.dtd,v 1.3 2004/02/27 18:34:59 jeremias Exp $ -->diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/core/TestBugInSomething.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/core/TestBugInSomething.javaindex 50d2bd81791..6cdff4bd5c9 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/core/TestBugInSomething.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/core/TestBugInSomething.java@@ -257,7 +257,6 @@ public class TestBugInSomething extends BaseTokenStreamTestCase {-119, 0, 92, 94, -36, 53, -9, -102, -18, 90, 94, -26, 31, 71, -20};Analyzer a = new Analyzer() {- @SuppressWarnings("deprecation")@Overrideprotected TokenStreamComponents createComponents(String fieldName) {Tokenizer tokenizer = new WikipediaTokenizer();diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/core/TestRandomChains.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/core/TestRandomChains.javaindex a0f5fb8ad82..10358c752c8 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/core/TestRandomChains.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/core/TestRandomChains.java@@ -82,6 +82,7 @@ import org.apache.lucene.analysis.miscellaneous.LimitTokenOffsetFilter;import org.apache.lucene.analysis.miscellaneous.LimitTokenPositionFilter;import org.apache.lucene.analysis.miscellaneous.StemmerOverrideFilter;import org.apache.lucene.analysis.miscellaneous.StemmerOverrideFilter.StemmerOverrideMap;+import org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter;import org.apache.lucene.analysis.miscellaneous.WordDelimiterGraphFilter;import org.apache.lucene.analysis.path.PathHierarchyTokenizer;import org.apache.lucene.analysis.path.ReversePathHierarchyTokenizer;@@ -111,7 +112,6 @@ import org.tartarus.snowball.SnowballProgram;import org.xml.sax.InputSource;/** tests random analysis chains */-@SuppressWarnings("deprecation")public class TestRandomChains extends BaseTokenStreamTestCase {static List<Constructor<? extends Tokenizer>> tokenizers;@@ -193,7 +193,7 @@ public class TestRandomChains extends BaseTokenStreamTestCase {// TODO: it seems to mess up offsets!?WikipediaTokenizer.class,// TODO: needs to be a tokenizer, doesnt handle graph inputs properly (a shingle or similar following will then cause pain)- org.apache.lucene.analysis.miscellaneous.WordDelimiterFilter.class,+ WordDelimiterFilter.class,// Cannot correct offsets when a char filter had changed them:WordDelimiterGraphFilter.class,// requires a special encoded token value, so it may fail with random data:@@ -321,7 +321,6 @@ public class TestRandomChains extends BaseTokenStreamTestCase {}}- @SuppressWarnings("serial")private static final Map<Class<?>,Function<Random,Object>> argProducers = new IdentityHashMap<Class<?>,Function<Random,Object>>() {{put(int.class, random -> {// TODO: could cause huge ram usage to use full int range for some filtersdiff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/custom/TestCustomAnalyzer.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/custom/TestCustomAnalyzer.javaindex 9313a998474..1afb90eb764 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/custom/TestCustomAnalyzer.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/custom/TestCustomAnalyzer.java@@ -47,7 +47,6 @@ import org.apache.lucene.util.BytesRef;import org.apache.lucene.util.SetOnce.AlreadySetException;import org.apache.lucene.util.Version;-@SuppressWarnings("deprecation")public class TestCustomAnalyzer extends BaseTokenStreamTestCase {// Test some examples (TODO: we only check behavior, we may need something like TestRandomChains...)diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestConcatenateGraphFilter.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestConcatenateGraphFilter.javaindex 8c429a55cf7..61219352d95 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestConcatenateGraphFilter.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestConcatenateGraphFilter.java@@ -25,6 +25,7 @@ import org.apache.lucene.analysis.StopFilter;import org.apache.lucene.analysis.TokenFilter;import org.apache.lucene.analysis.TokenStream;import org.apache.lucene.analysis.Tokenizer;+import org.apache.lucene.analysis.synonym.SynonymFilter;import org.apache.lucene.analysis.synonym.SynonymGraphFilter;import org.apache.lucene.analysis.synonym.SynonymMap;import org.apache.lucene.util.CharsRef;@@ -68,19 +69,17 @@ public class TestConcatenateGraphFilter extends BaseTokenStreamTestCase {assertTokenStreamContents(stream, new String[]{builder.toCharsRef().toString()}, null, null, new int[]{1});}- @SuppressWarnings("deprecation")@Testpublic void testWithSynonym() throws Exception {SynonymMap.Builder builder = new SynonymMap.Builder(true);builder.add(new CharsRef("mykeyword"), new CharsRef("mysynonym"), true);Tokenizer tokenizer = new MockTokenizer(MockTokenizer.WHITESPACE, true);tokenizer.setReader(new StringReader("mykeyword"));- org.apache.lucene.analysis.synonym.SynonymFilter filter = new org.apache.lucene.analysis.synonym.SynonymFilter(tokenizer, builder.build(), true);+ SynonymFilter filter = new SynonymFilter(tokenizer, builder.build(), true);ConcatenateGraphFilter stream = new ConcatenateGraphFilter(filter);assertTokenStreamContents(stream, new String[] {"mykeyword", "mysynonym"}, null, null, new int[] { 1, 0 });}- @SuppressWarnings("deprecation")@Testpublic void testWithSynonyms() throws Exception {SynonymMap.Builder builder = new SynonymMap.Builder(true);@@ -88,7 +87,7 @@ public class TestConcatenateGraphFilter extends BaseTokenStreamTestCase {Tokenizer tokenStream = new MockTokenizer(MockTokenizer.WHITESPACE, true);String input = "mykeyword another keyword";tokenStream.setReader(new StringReader(input));- org.apache.lucene.analysis.synonym.SynonymFilter filter = new org.apache.lucene.analysis.synonym.SynonymFilter(tokenStream, builder.build(), true);+ SynonymFilter filter = new SynonymFilter(tokenStream, builder.build(), true);ConcatenateGraphFilter stream = new ConcatenateGraphFilter(filter, SEP_LABEL, false, 100);String[] expectedOutputs = new String[2];CharsRefBuilder expectedOutput = new CharsRefBuilder();@@ -133,7 +132,6 @@ public class TestConcatenateGraphFilter extends BaseTokenStreamTestCase {}}- @SuppressWarnings("deprecation")@Testpublic void testValidNumberOfExpansions() throws IOException {SynonymMap.Builder builder = new SynonymMap.Builder(true);@@ -147,7 +145,7 @@ public class TestConcatenateGraphFilter extends BaseTokenStreamTestCase {}MockTokenizer tokenizer = new MockTokenizer(MockTokenizer.WHITESPACE, true);tokenizer.setReader(new StringReader(valueBuilder.toString()));- org.apache.lucene.analysis.synonym.SynonymFilter filter = new org.apache.lucene.analysis.synonym.SynonymFilter(tokenizer, builder.build(), true);+ SynonymFilter filter = new SynonymFilter(tokenizer, builder.build(), true);int count;try (ConcatenateGraphFilter stream = new ConcatenateGraphFilter(filter)) {diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestFixBrokenOffsetsFilter.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestFixBrokenOffsetsFilter.javaindex 6d670604643..ada5014334f 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestFixBrokenOffsetsFilter.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestFixBrokenOffsetsFilter.java@@ -31,7 +31,6 @@ import org.apache.lucene.store.Directory;public class TestFixBrokenOffsetsFilter extends BaseTokenStreamTestCase {- @SuppressWarnings("deprecation")public void testBogusTermVectors() throws IOException {Directory dir = newDirectory();IndexWriter iw = new IndexWriter(dir, newIndexWriterConfig(null));diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestLimitTokenPositionFilter.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestLimitTokenPositionFilter.javaindex 88aacd51d50..46d3025b14d 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestLimitTokenPositionFilter.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestLimitTokenPositionFilter.java@@ -20,6 +20,7 @@ import org.apache.lucene.analysis.Analyzer;import org.apache.lucene.analysis.BaseTokenStreamTestCase;import org.apache.lucene.analysis.MockTokenizer;import org.apache.lucene.analysis.TokenStream;+import org.apache.lucene.analysis.synonym.SynonymFilter;import org.apache.lucene.analysis.synonym.SynonymMap;import org.apache.lucene.util.CharsRef;import org.apache.lucene.util.CharsRefBuilder;@@ -59,7 +60,6 @@ public class TestLimitTokenPositionFilter extends BaseTokenStreamTestCase {}}- @SuppressWarnings("deprecation")public void testMaxPosition3WithSynomyms() throws IOException {for (final boolean consumeAll : new boolean[]{true, false}) {MockTokenizer tokenizer = whitespaceMockTokenizer("one two three four five");@@ -76,7 +76,7 @@ public class TestLimitTokenPositionFilter extends BaseTokenStreamTestCase {SynonymMap.Builder.join(new String[]{"dopple", "ganger"}, multiWordCharsRef);builder.add(new CharsRef("two"), multiWordCharsRef.get(), true);SynonymMap synonymMap = builder.build();- TokenStream stream = new org.apache.lucene.analysis.synonym.SynonymFilter(tokenizer, synonymMap, true);+ TokenStream stream = new SynonymFilter(tokenizer, synonymMap, true);stream = new LimitTokenPositionFilter(stream, 3, consumeAll);// "only", the 4th word of multi-word synonym "and indubitably single only" is not emitted, since its position is greater than 3.diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestRemoveDuplicatesTokenFilter.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestRemoveDuplicatesTokenFilter.javaindex 84b7d1047ed..d1e2e2ee477 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestRemoveDuplicatesTokenFilter.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestRemoveDuplicatesTokenFilter.java@@ -156,7 +156,6 @@ public class TestRemoveDuplicatesTokenFilter extends BaseTokenStreamTestCase {@Overrideprotected TokenStreamComponents createComponents(String fieldName) {Tokenizer tokenizer = new MockTokenizer(MockTokenizer.SIMPLE, true);- @SuppressWarnings("deprecation")TokenStream stream = new SynonymFilter(tokenizer, map, ignoreCase);return new TokenStreamComponents(tokenizer, new RemoveDuplicatesTokenFilter(stream));}diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestWordDelimiterFilter.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestWordDelimiterFilter.javaindex 2267f0cb995..790e7589e97 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestWordDelimiterFilter.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/miscellaneous/TestWordDelimiterFilter.java@@ -54,7 +54,6 @@ import static org.apache.lucene.analysis.miscellaneous.WordDelimiterIterator.DEF* TODO: should explicitly test things like protWords and not rely on* the factory tests in Solr.*/-@SuppressWarnings("deprecation")public class TestWordDelimiterFilter extends BaseTokenStreamTestCase {/*diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/ngram/EdgeNGramTokenizerTest.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/ngram/EdgeNGramTokenizerTest.javaindex e96ced8700e..7fbea5f8d60 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/ngram/EdgeNGramTokenizerTest.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/ngram/EdgeNGramTokenizerTest.java@@ -119,7 +119,6 @@ public class EdgeNGramTokenizerTest extends BaseTokenStreamTestCase {false);}- @SuppressWarnings("deprecation")private static void testNGrams(int minGram, int maxGram, int length, final String nonTokenChars) throws IOException {final String s = RandomStrings.randomAsciiOfLength(random(), length);testNGrams(minGram, maxGram, s, nonTokenChars);diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/ngram/NGramTokenizerTest.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/ngram/NGramTokenizerTest.javaindex adcc9ee3d34..cb54fa2fc44 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/ngram/NGramTokenizerTest.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/ngram/NGramTokenizerTest.java@@ -119,7 +119,6 @@ public class NGramTokenizerTest extends BaseTokenStreamTestCase {}}- @SuppressWarnings("deprecation")private static void testNGrams(int minGram, int maxGram, int length, final String nonTokenChars) throws IOException {final String s = RandomStrings.randomAsciiOfLength(random(), length);testNGrams(minGram, maxGram, s, nonTokenChars);diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/synonym/TestSolrSynonymParser.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/synonym/TestSolrSynonymParser.javaindex c81b89417ea..748b177a25f 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/synonym/TestSolrSynonymParser.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/synonym/TestSolrSynonymParser.java@@ -47,7 +47,6 @@ public class TestSolrSynonymParser extends BaseSynonymParserTestCase {analyzer.close();analyzer = new Analyzer() {- @SuppressWarnings("deprecation")@Overrideprotected TokenStreamComponents createComponents(String fieldName) {Tokenizer tokenizer = new MockTokenizer(MockTokenizer.WHITESPACE, true);@@ -139,7 +138,6 @@ public class TestSolrSynonymParser extends BaseSynonymParserTestCase {final SynonymMap map = parser.build();analyzer.close();analyzer = new Analyzer() {- @SuppressWarnings("deprecation")@Overrideprotected TokenStreamComponents createComponents(String fieldName) {Tokenizer tokenizer = new MockTokenizer(MockTokenizer.KEYWORD, false);@@ -173,7 +171,6 @@ public class TestSolrSynonymParser extends BaseSynonymParserTestCase {analyzer.close();analyzer = new Analyzer() {- @SuppressWarnings("deprecation")@Overrideprotected TokenStreamComponents createComponents(String fieldName) {Tokenizer tokenizer = new MockTokenizer(MockTokenizer.WHITESPACE, true);diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/synonym/TestSynonymFilterFactory.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/synonym/TestSynonymFilterFactory.javaindex ae3b475f03f..e3bb00ab607 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/synonym/TestSynonymFilterFactory.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/synonym/TestSynonymFilterFactory.java@@ -30,7 +30,6 @@ import org.apache.lucene.util.Version;public class TestSynonymFilterFactory extends BaseTokenStreamFactoryTestCase {/** checks for synonyms of "GB" in synonyms.txt */- @SuppressWarnings("deprecation")private void checkSolrSynonyms(TokenFilterFactory factory) throws Exception {Reader reader = new StringReader("GB");TokenStream stream = whitespaceMockTokenizer(reader);@@ -42,7 +41,6 @@ public class TestSynonymFilterFactory extends BaseTokenStreamFactoryTestCase {}/** checks for synonyms of "second" in synonyms-wordnet.txt */- @SuppressWarnings("deprecation")private void checkWordnetSynonyms(TokenFilterFactory factory) throws Exception {Reader reader = new StringReader("second");TokenStream stream = whitespaceMockTokenizer(reader);diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/synonym/TestSynonymMapFilter.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/synonym/TestSynonymMapFilter.javaindex 0b4a08c0352..0fbbd2e58cc 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/synonym/TestSynonymMapFilter.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/synonym/TestSynonymMapFilter.java@@ -39,7 +39,6 @@ import org.apache.lucene.analysis.tokenattributes.*;import org.apache.lucene.util.CharsRefBuilder;import org.apache.lucene.util.TestUtil;-@SuppressWarnings("deprecation")public class TestSynonymMapFilter extends BaseTokenStreamTestCase {private SynonymMap.Builder b;diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/synonym/TestWordnetSynonymParser.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/synonym/TestWordnetSynonymParser.javaindex 62abd67d431..2449f8fd242 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/synonym/TestWordnetSynonymParser.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/synonym/TestWordnetSynonymParser.java@@ -45,7 +45,6 @@ public class TestWordnetSynonymParser extends BaseTokenStreamTestCase {analyzer.close();analyzer = new Analyzer() {- @SuppressWarnings("deprecation")@Overrideprotected TokenStreamComponents createComponents(String fieldName) {Tokenizer tokenizer = new MockTokenizer(MockTokenizer.WHITESPACE, false);diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/util/TestAnalysisSPILoader.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/util/TestAnalysisSPILoader.javaindex b2cdd353f94..2398c1e822c 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/util/TestAnalysisSPILoader.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/util/TestAnalysisSPILoader.java@@ -29,7 +29,6 @@ import org.apache.lucene.util.Version;public class TestAnalysisSPILoader extends LuceneTestCase {- @SuppressWarnings("serial")private Map<String,String> versionArgOnly() {return new HashMap<String, String>() {{put("luceneMatchVersion", Version.LATEST.toString());diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/util/TestFilesystemResourceLoader.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/util/TestFilesystemResourceLoader.javaindex 85b8607bc97..eaa6174ae7c 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/util/TestFilesystemResourceLoader.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/util/TestFilesystemResourceLoader.java@@ -54,7 +54,6 @@ public class TestFilesystemResourceLoader extends LuceneTestCase {rl.newInstance("org.apache.lucene.analysis.util.RollingCharBuffer", Object.class).getClass().getName());}- @SuppressWarnings("deprecation")public void testBaseDir() throws Exception {final Path base = createTempDir("fsResourceLoaderBase");Writer os = Files.newBufferedWriter(base.resolve("template.txt"), StandardCharsets.UTF_8);diff --git a/lucene/analysis/icu/src/java/org/apache/lucene/analysis/icu/ICUTransformFilter.java b/lucene/analysis/icu/src/java/org/apache/lucene/analysis/icu/ICUTransformFilter.javaindex 35f141003ca..bfe7c12a2a9 100644--- a/lucene/analysis/icu/src/java/org/apache/lucene/analysis/icu/ICUTransformFilter.java+++ b/lucene/analysis/icu/src/java/org/apache/lucene/analysis/icu/ICUTransformFilter.java@@ -73,7 +73,6 @@ public final class ICUTransformFilter extends TokenFilter {* @param input {@link TokenStream} to filter.* @param transform Transliterator to transform the text.*/- @SuppressWarnings("deprecation")public ICUTransformFilter(TokenStream input, Transliterator transform) {super(input);this.transform = transform;diff --git a/lucene/benchmark/src/java/org/apache/lucene/benchmark/byTask/feeds/SpatialDocMaker.java b/lucene/benchmark/src/java/org/apache/lucene/benchmark/byTask/feeds/SpatialDocMaker.javaindex 274bd428fff..b466e964cc9 100644--- a/lucene/benchmark/src/java/org/apache/lucene/benchmark/byTask/feeds/SpatialDocMaker.java+++ b/lucene/benchmark/src/java/org/apache/lucene/benchmark/byTask/feeds/SpatialDocMaker.java@@ -169,7 +169,6 @@ public class SpatialDocMaker extends DocMaker {final boolean bbox = config.get(configKeyPrefix + "bbox", false);return new ShapeConverter() {- @SuppressWarnings("deprecation")@Overridepublic Shape convert(Shape shape) {if (shape instanceof Point && (radiusDegrees != 0.0 || plusMinus != 0.0)) {@@ -218,7 +217,6 @@ public class SpatialDocMaker extends DocMaker {return doc;}- @SuppressWarnings("deprecation")public static Shape makeShapeFromString(SpatialStrategy strategy, String name, String shapeStr) {if (shapeStr != null && shapeStr.length() > 0) {try {diff --git a/lucene/benchmark/src/java/org/apache/lucene/benchmark/byTask/tasks/AnalyzerFactoryTask.java b/lucene/benchmark/src/java/org/apache/lucene/benchmark/byTask/tasks/AnalyzerFactoryTask.javaindex 518ede494b9..051a8fc0bd1 100644--- a/lucene/benchmark/src/java/org/apache/lucene/benchmark/byTask/tasks/AnalyzerFactoryTask.java+++ b/lucene/benchmark/src/java/org/apache/lucene/benchmark/byTask/tasks/AnalyzerFactoryTask.java@@ -288,7 +288,7 @@ public class AnalyzerFactoryTask extends PerfTask {* @param stok stream tokenizer from which to draw analysis factory params* @param clazz analysis factory class to instantiate*/- @SuppressWarnings({"fallthrough", "deprecation"})+ @SuppressWarnings("fallthrough")private void createAnalysisPipelineComponent(StreamTokenizer stok, Class<? extends AbstractAnalysisFactory> clazz) {Map<String,String> argMap = new HashMap<>();diff --git a/lucene/core/src/java/org/apache/lucene/util/fst/PositiveIntOutputs.java b/lucene/core/src/java/org/apache/lucene/util/fst/PositiveIntOutputs.javaindex c6ea6f263f4..bc9806dcddd 100644--- a/lucene/core/src/java/org/apache/lucene/util/fst/PositiveIntOutputs.java+++ b/lucene/core/src/java/org/apache/lucene/util/fst/PositiveIntOutputs.java@@ -33,7 +33,6 @@ import org.apache.lucene.util.SuppressForbidden;@SuppressForbidden(reason = "Uses a Long instance as a marker")public final class PositiveIntOutputs extends Outputs<Long> {- @SuppressWarnings("deprecation")private final static Long NO_OUTPUT = new Long(0);private final static PositiveIntOutputs singleton = new PositiveIntOutputs();diff --git a/lucene/core/src/test/org/apache/lucene/analysis/TestCharArraySet.java b/lucene/core/src/test/org/apache/lucene/analysis/TestCharArraySet.javaindex a28de9266d8..e51f2072087 100644--- a/lucene/core/src/test/org/apache/lucene/analysis/TestCharArraySet.java+++ b/lucene/core/src/test/org/apache/lucene/analysis/TestCharArraySet.java@@ -57,7 +57,6 @@ public class TestCharArraySet extends LuceneTestCase {assertTrue(set.contains(new String(findme,1,4)));}- @SuppressWarnings("deprecation")@SuppressForbidden(reason = "Explicitly checking new Integers")public void testObjectContains() {CharArraySet set = new CharArraySet(10, true);@@ -212,6 +211,7 @@ public class TestCharArraySet extends LuceneTestCase {}}+ @SuppressWarnings("deprecated")public void testCopyCharArraySetBWCompat() {CharArraySet setIngoreCase = new CharArraySet(10, true);CharArraySet setCaseSensitive = new CharArraySet(10, false);diff --git a/lucene/core/src/test/org/apache/lucene/document/TestDocument.java b/lucene/core/src/test/org/apache/lucene/document/TestDocument.javaindex 1d026852ca9..50c1ed0a919 100644--- a/lucene/core/src/test/org/apache/lucene/document/TestDocument.java+++ b/lucene/core/src/test/org/apache/lucene/document/TestDocument.java@@ -212,7 +212,6 @@ public class TestDocument extends LuceneTestCase {dir.close();}- @SuppressWarnings("deprecation")public void testGetValues() {Document doc = makeDocumentWithFields();assertEquals(new String[] {"test1", "test2"},diff --git a/lucene/core/src/test/org/apache/lucene/index/TestFieldUpdatesBuffer.java b/lucene/core/src/test/org/apache/lucene/index/TestFieldUpdatesBuffer.javaindex cb387fd4288..0ca3af8de66 100644--- a/lucene/core/src/test/org/apache/lucene/index/TestFieldUpdatesBuffer.java+++ b/lucene/core/src/test/org/apache/lucene/index/TestFieldUpdatesBuffer.java@@ -149,7 +149,6 @@ public class TestFieldUpdatesBuffer extends LuceneTestCase {assertFalse(buffer.isNumeric());}- @SuppressWarnings("unchecked")public <T extends DocValuesUpdate> T getRandomUpdate(boolean binary) {String termField = RandomPicks.randomFrom(random(), Arrays.asList("id", "_id", "some_other_field"));String docId = "" + random().nextInt(10);diff --git a/lucene/core/src/test/org/apache/lucene/search/TestMultiTermConstantScore.java b/lucene/core/src/test/org/apache/lucene/search/TestMultiTermConstantScore.javaindex 94537218a98..69e1e1039b2 100644--- a/lucene/core/src/test/org/apache/lucene/search/TestMultiTermConstantScore.java+++ b/lucene/core/src/test/org/apache/lucene/search/TestMultiTermConstantScore.java@@ -33,6 +33,8 @@ import org.junit.Test;import java.io.IOException;+import junit.framework.Assert;+public class TestMultiTermConstantScore extends BaseTestRangeFilter {/** threshold for comparing floats */@@ -41,9 +43,8 @@ public class TestMultiTermConstantScore extends BaseTestRangeFilter {static Directory small;static IndexReader reader;- @SuppressWarnings("deprecation")static public void assertEquals(String m, int e, int a) {- junit.framework.Assert.assertEquals(m, e, a);+ Assert.assertEquals(m, e, a);}@BeforeClassdiff --git a/lucene/core/src/test/org/apache/lucene/search/TestSearchAfter.java b/lucene/core/src/test/org/apache/lucene/search/TestSearchAfter.javaindex 90a25723331..2ce677c84e6 100644--- a/lucene/core/src/test/org/apache/lucene/search/TestSearchAfter.java+++ b/lucene/core/src/test/org/apache/lucene/search/TestSearchAfter.java@@ -281,7 +281,6 @@ public class TestSearchAfter extends LuceneTestCase {assertEquals(all.scoreDocs.length, pageStart);}- @SuppressWarnings("deprecation")void assertPage(int pageStart, TopDocs all, TopDocs paged) throws IOException {assertEquals(all.totalHits.value, paged.totalHits.value);for (int i = 0; i < paged.scoreDocs.length; i++) {diff --git a/lucene/core/src/test/org/apache/lucene/util/TestCharsRef.java b/lucene/core/src/test/org/apache/lucene/util/TestCharsRef.javaindex 8ed9352e8e9..079b3b774b5 100644--- a/lucene/core/src/test/org/apache/lucene/util/TestCharsRef.java+++ b/lucene/core/src/test/org/apache/lucene/util/TestCharsRef.java@@ -20,7 +20,6 @@ import java.util.Arrays;public class TestCharsRef extends LuceneTestCase {- @SuppressWarnings("deprecation")public void testUTF16InUTF8Order() {final int numStrings = atLeast(1000);BytesRef utf8[] = new BytesRef[numStrings];diff --git a/lucene/core/src/test/org/apache/lucene/util/TestVersion.java b/lucene/core/src/test/org/apache/lucene/util/TestVersion.javaindex 02d566ea10a..e19c6150812 100644--- a/lucene/core/src/test/org/apache/lucene/util/TestVersion.java+++ b/lucene/core/src/test/org/apache/lucene/util/TestVersion.java@@ -23,7 +23,6 @@ import java.text.ParseException;import java.util.Locale;import java.util.Random;-@SuppressWarnings("deprecation")public class TestVersion extends LuceneTestCase {public void testOnOrAfter() throws Exception {diff --git a/lucene/core/src/test/org/apache/lucene/util/TestVirtualMethod.java b/lucene/core/src/test/org/apache/lucene/util/TestVirtualMethod.javanew file mode 100644index 00000000000..4dfe86b3f50--- /dev/null+++ b/lucene/core/src/test/org/apache/lucene/util/TestVirtualMethod.java@@ -0,0 +1,95 @@+/*+ * Licensed to the Apache Software Foundation (ASF) under one or more+ * contributor license agreements. See the NOTICE file distributed with+ * this work for additional information regarding copyright ownership.+ * The ASF licenses this file to You under the Apache License, Version 2.0+ * (the "License"); you may not use this file except in compliance with+ * the License. You may obtain a copy of the License at+ *+ * http://www.apache.org/licenses/LICENSE-2.0+ *+ * Unless required by applicable law or agreed to in writing, software+ * distributed under the License is distributed on an "AS IS" BASIS,+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.+ * See the License for the specific language governing permissions and+ * limitations under the License.+ */+package org.apache.lucene.util;++public class TestVirtualMethod extends LuceneTestCase {++ private static final VirtualMethod<TestVirtualMethod> publicTestMethod =+ new VirtualMethod<>(TestVirtualMethod.class, "publicTest", String.class);+ private static final VirtualMethod<TestVirtualMethod> protectedTestMethod =+ new VirtualMethod<>(TestVirtualMethod.class, "protectedTest", int.class);++ public void publicTest(String test) {}+ protected void protectedTest(int test) {}++ static class TestClass1 extends TestVirtualMethod {+ @Override+ public void publicTest(String test) {}+ @Override+ protected void protectedTest(int test) {}+ }++ static class TestClass2 extends TestClass1 {+ @Override // make it public here+ public void protectedTest(int test) {}+ }++ static class TestClass3 extends TestClass2 {+ @Override+ public void publicTest(String test) {}+ }++ static class TestClass4 extends TestVirtualMethod {+ }++ static class TestClass5 extends TestClass4 {+ }++ public void testGeneral() {+ assertEquals(0, publicTestMethod.getImplementationDistance(this.getClass()));+ assertEquals(1, publicTestMethod.getImplementationDistance(TestClass1.class));+ assertEquals(1, publicTestMethod.getImplementationDistance(TestClass2.class));+ assertEquals(3, publicTestMethod.getImplementationDistance(TestClass3.class));+ assertFalse(publicTestMethod.isOverriddenAsOf(TestClass4.class));+ assertFalse(publicTestMethod.isOverriddenAsOf(TestClass5.class));++ assertEquals(0, protectedTestMethod.getImplementationDistance(this.getClass()));+ assertEquals(1, protectedTestMethod.getImplementationDistance(TestClass1.class));+ assertEquals(2, protectedTestMethod.getImplementationDistance(TestClass2.class));+ assertEquals(2, protectedTestMethod.getImplementationDistance(TestClass3.class));+ assertFalse(protectedTestMethod.isOverriddenAsOf(TestClass4.class));+ assertFalse(protectedTestMethod.isOverriddenAsOf(TestClass5.class));++ assertTrue(VirtualMethod.compareImplementationDistance(TestClass3.class, publicTestMethod, protectedTestMethod) > 0);+ assertEquals(0, VirtualMethod.compareImplementationDistance(TestClass5.class, publicTestMethod, protectedTestMethod));+ }++ @SuppressWarnings({"rawtypes","unchecked"})+ public void testExceptions() {+ // LuceneTestCase is not a subclass and can never override publicTest(String)+ expectThrows(IllegalArgumentException.class, () -> {+ // cast to Class to remove generics:+ publicTestMethod.getImplementationDistance((Class) LuceneTestCase.class);+ });++ // Method bogus() does not exist, so IAE should be thrown+ expectThrows(IllegalArgumentException.class, () -> {+ new VirtualMethod<>(TestVirtualMethod.class, "bogus");+ });++ // Method publicTest(String) is not declared in TestClass2, so IAE should be thrown+ expectThrows(IllegalArgumentException.class, () -> {+ new VirtualMethod<>(TestClass2.class, "publicTest", String.class);+ });++ // try to create a second instance of the same baseClass / method combination+ expectThrows(UnsupportedOperationException.class, () -> {+ new VirtualMethod<>(TestVirtualMethod.class, "publicTest", String.class);+ });+ }++}diff --git a/lucene/core/src/test/org/apache/lucene/util/fst/Test2BFST.java b/lucene/core/src/test/org/apache/lucene/util/fst/Test2BFST.javaindex 7948ef1c57b..cc093b3cdba 100644--- a/lucene/core/src/test/org/apache/lucene/util/fst/Test2BFST.java+++ b/lucene/core/src/test/org/apache/lucene/util/fst/Test2BFST.java@@ -39,7 +39,6 @@ public class Test2BFST extends LuceneTestCase {private static long LIMIT = 3L*1024*1024*1024;- @SuppressWarnings("deprecation")public void test() throws Exception {assumeWorkingMMapOnWindows();diff --git a/lucene/core/src/test/org/apache/lucene/util/fst/TestFSTs.java b/lucene/core/src/test/org/apache/lucene/util/fst/TestFSTs.javaindex 319079d1a65..316cbdf1e42 100644--- a/lucene/core/src/test/org/apache/lucene/util/fst/TestFSTs.java+++ b/lucene/core/src/test/org/apache/lucene/util/fst/TestFSTs.java@@ -567,7 +567,7 @@ public class TestFSTs extends LuceneTestCase {} else {// Get by outputfinal Long output = (Long) getOutput(intsRef.get(), ord);- @SuppressWarnings({"unchecked", "deprecation"}) final IntsRef actual = Util.getByOutput((FST<Long>) fst, output.longValue());+ @SuppressWarnings("unchecked") final IntsRef actual = Util.getByOutput((FST<Long>) fst, output.longValue());if (actual == null) {throw new RuntimeException("unexpected null input from output=" + output);}@@ -787,7 +787,6 @@ public class TestFSTs extends LuceneTestCase {}*/- @SuppressWarnings("deprecation")public void testSimple() throws Exception {// Get outputs -- passing true means FST will sharediff --git a/lucene/facet/src/java/org/apache/lucene/facet/DrillSideways.java b/lucene/facet/src/java/org/apache/lucene/facet/DrillSideways.javaindex e9a38e533ce..15df7e3d957 100644--- a/lucene/facet/src/java/org/apache/lucene/facet/DrillSideways.java+++ b/lucene/facet/src/java/org/apache/lucene/facet/DrillSideways.java@@ -404,7 +404,6 @@ public class DrillSideways {}/** Runs a search, using a {@link CollectorManager} to gather and merge search results */- @SuppressWarnings("unchecked")public <R> ConcurrentDrillSidewaysResult<R> search(final DrillDownQuery query,final CollectorManager<?, R> hitCollectorManager) throws IOException {diff --git a/lucene/grouping/src/test/org/apache/lucene/search/grouping/TestGrouping.java b/lucene/grouping/src/test/org/apache/lucene/search/grouping/TestGrouping.javaindex dc19f6d7c6b..87a1d97efe7 100644--- a/lucene/grouping/src/test/org/apache/lucene/search/grouping/TestGrouping.java+++ b/lucene/grouping/src/test/org/apache/lucene/search/grouping/TestGrouping.java@@ -287,11 +287,9 @@ public class TestGrouping extends LuceneTestCase {private Collection<SearchGroup<BytesRef>> getSearchGroups(FirstPassGroupingCollector<?> c, int groupOffset) throws IOException {if (TermGroupSelector.class.isAssignableFrom(c.getGroupSelector().getClass())) {- @SuppressWarnings("unchecked")FirstPassGroupingCollector<BytesRef> collector = (FirstPassGroupingCollector<BytesRef>) c;return collector.getTopGroups(groupOffset);} else if (ValueSourceGroupSelector.class.isAssignableFrom(c.getGroupSelector().getClass())) {- @SuppressWarnings("unchecked")FirstPassGroupingCollector<MutableValue> collector = (FirstPassGroupingCollector<MutableValue>) c;Collection<SearchGroup<MutableValue>> mutableValueGroups = collector.getTopGroups(groupOffset);if (mutableValueGroups == null) {@@ -406,6 +404,7 @@ public class TestGrouping extends LuceneTestCase {};}+ @SuppressWarnings({"unchecked","rawtypes"})private Comparable<?>[] fillFields(GroupDoc d, Sort sort) {final SortField[] sortFields = sort.getSort();final Comparable<?>[] fields = new Comparable[sortFields.length];@@ -491,7 +490,7 @@ public class TestGrouping extends LuceneTestCase {final int limit = Math.min(groupOffset + topNGroups, groups.size());final Comparator<GroupDoc> docSortComp = getComparator(docSort);- @SuppressWarnings({"unchecked"})+ @SuppressWarnings({"unchecked","rawtypes"})final GroupDocs<BytesRef>[] result = new GroupDocs[limit-groupOffset];int totalGroupedHitCount = 0;for(int idx=groupOffset;idx < limit;idx++) {@@ -1043,7 +1042,7 @@ public class TestGrouping extends LuceneTestCase {}// Get block grouping result:sBlocks.search(query, c4);- @SuppressWarnings({"unchecked"})+ @SuppressWarnings({"unchecked","rawtypes"})final TopGroups<BytesRef> tempTopGroupsBlocks = (TopGroups<BytesRef>) c3.getTopGroups(docSort, groupOffset, docOffset, docOffset+docsPerGroup);final TopGroups<BytesRef> groupsResultBlocks;if (doAllGroups && tempTopGroupsBlocks != null) {@@ -1199,7 +1198,7 @@ public class TestGrouping extends LuceneTestCase {if (mergedTopGroups != null) {// Now 2nd pass:- @SuppressWarnings({"unchecked"})+ @SuppressWarnings({"unchecked","rawtypes"})final TopGroups<BytesRef>[] shardTopGroups = new TopGroups[subSearchers.length];for(int shardIDX=0;shardIDX<subSearchers.length;shardIDX++) {final TopGroupsCollector<?> secondPassCollector = createSecondPassCollector(firstPassGroupingCollectors.get(shardIDX),diff --git a/lucene/highlighter/src/test/org/apache/lucene/search/highlight/HighlighterTest.java b/lucene/highlighter/src/test/org/apache/lucene/search/highlight/HighlighterTest.javaindex dfdff00c30a..c555297fa95 100644--- a/lucene/highlighter/src/test/org/apache/lucene/search/highlight/HighlighterTest.java+++ b/lucene/highlighter/src/test/org/apache/lucene/search/highlight/HighlighterTest.java@@ -2005,7 +2005,6 @@ public class HighlighterTest extends BaseTokenStreamTestCase implements FormatteTopDocs hits = searcher.search(query, 10);assertEquals(1, hits.scoreDocs.length);- @SuppressWarnings("deprecation")TokenStream stream = TokenSources.getAnyTokenStream(searcher.getIndexReader(), 0, FIELD_NAME, analyzer);if (random().nextBoolean()) {stream = new CachingTokenFilter(stream);//conceals detection of TokenStreamFromTermVectordiff --git a/lucene/join/src/java/org/apache/lucene/search/join/ToParentBlockJoinSortField.java b/lucene/join/src/java/org/apache/lucene/search/join/ToParentBlockJoinSortField.javaindex dce141601a8..fef167e62f9 100644--- a/lucene/join/src/java/org/apache/lucene/search/join/ToParentBlockJoinSortField.java+++ b/lucene/join/src/java/org/apache/lucene/search/join/ToParentBlockJoinSortField.java@@ -107,7 +107,6 @@ public class ToParentBlockJoinSortField extends SortField {private FieldComparator<?> getStringComparator(int numHits) {return new FieldComparator.TermOrdValComparator(numHits, getField(), missingValue == STRING_LAST) {- @SuppressWarnings("deprecation")@Overrideprotected SortedDocValues getSortedDocValues(LeafReaderContext context, String field) throws IOException {SortedSetDocValues sortedSet = DocValues.getSortedSet(context.reader(), field);@@ -127,7 +126,6 @@ public class ToParentBlockJoinSortField extends SortField {private FieldComparator<?> getIntComparator(int numHits) {return new FieldComparator.IntComparator(numHits, getField(), (Integer) missingValue) {- @SuppressWarnings("deprecation")@Overrideprotected NumericDocValues getNumericDocValues(LeafReaderContext context, String field) throws IOException {SortedNumericDocValues sortedNumeric = DocValues.getSortedNumeric(context.reader(), field);@@ -146,7 +144,6 @@ public class ToParentBlockJoinSortField extends SortField {private FieldComparator<?> getLongComparator(int numHits) {return new FieldComparator.LongComparator(numHits, getField(), (Long) missingValue) {- @SuppressWarnings("deprecation")@Overrideprotected NumericDocValues getNumericDocValues(LeafReaderContext context, String field) throws IOException {SortedNumericDocValues sortedNumeric = DocValues.getSortedNumeric(context.reader(), field);@@ -165,7 +162,6 @@ public class ToParentBlockJoinSortField extends SortField {private FieldComparator<?> getFloatComparator(int numHits) {return new FieldComparator.FloatComparator(numHits, getField(), (Float) missingValue) {- @SuppressWarnings("deprecation")@Overrideprotected NumericDocValues getNumericDocValues(LeafReaderContext context, String field) throws IOException {SortedNumericDocValues sortedNumeric = DocValues.getSortedNumeric(context.reader(), field);@@ -190,7 +186,6 @@ public class ToParentBlockJoinSortField extends SortField {private FieldComparator<?> getDoubleComparator(int numHits) {return new FieldComparator.DoubleComparator(numHits, getField(), (Double) missingValue) {- @SuppressWarnings("deprecation")@Overrideprotected NumericDocValues getNumericDocValues(LeafReaderContext context, String field) throws IOException {SortedNumericDocValues sortedNumeric = DocValues.getSortedNumeric(context.reader(), field);diff --git a/lucene/join/src/test/org/apache/lucene/search/join/TestBlockJoinSelector.java b/lucene/join/src/test/org/apache/lucene/search/join/TestBlockJoinSelector.javaindex d88a87d78ed..838826fcbb4 100644--- a/lucene/join/src/test/org/apache/lucene/search/join/TestBlockJoinSelector.java+++ b/lucene/join/src/test/org/apache/lucene/search/join/TestBlockJoinSelector.java@@ -108,7 +108,6 @@ public class TestBlockJoinSelector extends LuceneTestCase {: ((NumericDocValues) sdv).advanceExact(target);}- @SuppressWarnings("deprecation")public void testSortedSelector() throws IOException {final BitSet parents = new FixedBitSet(20);parents.set(0);@@ -218,7 +217,6 @@ public class TestBlockJoinSelector extends LuceneTestCase {}}- @SuppressWarnings("deprecation")public void testNumericSelector() throws Exception {final BitSet parents = new FixedBitSet(20);parents.set(0);diff --git a/lucene/licenses/jetty-NOTICE.txt b/lucene/licenses/jetty-NOTICE.txtindex b6817e12bc3..e9461a8e86e 100644--- a/lucene/licenses/jetty-NOTICE.txt+++ b/lucene/licenses/jetty-NOTICE.txt@@ -31,18 +31,18 @@ repository ("Repository") in CVS modules ("Modules") and made availableas downloadable archives ("Downloads").</p><ul>- <li>Content may be structured and packaged into modules to+ <li>Content may be structured and packaged into modules tofacilitate delivering, extending, and upgrading the Content. Typicalmodules may include plug-ins ("Plug-ins"), plug-in fragments("Fragments"), and features ("Features").</li>- <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li>- <li>A+ <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li>+ <li>AFeature is a bundle of one or more Plug-ins and/or Fragments andassociated material. Each Feature may be packaged as a sub-directory ina directory named "features". Within a Feature, files named"feature.xml" may contain a list of the names and version numbers ofthe Plug-ins and/or Fragments associated with that Feature.</li>- <li>Features+ <li>Featuresmay also include other Features ("Included Features"). Within aFeature, files named "feature.xml" may contain a list of the names andversion numbers of Included Features.</li>@@ -57,13 +57,13 @@ directory of a Download or Moduleincluding, but not limited to the following locations:</p><ul>- <li>The top-level (root) directory</li>- <li>Plug-in and Fragment directories</li>- <li>Inside Plug-ins and Fragments packaged as JARs</li>- <li>Sub-directories of the directory named "src" of certain Plug-ins</li>- <li>Feature directories</li>+ <li>The top-level (root) directory</li>+ <li>Plug-in and Fragment directories</li>+ <li>Inside Plug-ins and Fragments packaged as JARs</li>+ <li>Sub-directories of the directory named "src" of certain Plug-ins</li>+ <li>Feature directories</li></ul>-+<p>Note: if a Feature made available by the Eclipse Foundation isinstalled using the Eclipse Update Manager, you must agree to a license("Feature Update License") during the@@ -84,12 +84,12 @@ CONDITIONS. SOME OF THESEOTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p><ul>- <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>- <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>- <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>- <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>- <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>- <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li>+ <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>+ <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>+ <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>+ <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>+ <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>+ <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li></ul><p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS ANDdiff --git a/lucene/licenses/junit-LICENSE-CPL.txt b/lucene/licenses/junit-LICENSE-CPL.txtindex e3f47c46371..4efdc7b204b 100644--- a/lucene/licenses/junit-LICENSE-CPL.txt+++ b/lucene/licenses/junit-LICENSE-CPL.txt@@ -10,8 +10,8 @@ THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS COMMON PUBLIC LICENa) in the case of the initial Contributor, the initial code and documentation distributed under this Agreement, andb) in the case of each subsequent Contributor:-i) changes to the Program, and-ii) additions to the Program;+i) changes to the Program, and+ii) additions to the Program;where such changes and/or additions to the Program originate from and are distributed by that particular Contributor. A Contribution 'originates' from a Contributor if it was added to the Program by such Contributor itself or anyone acting on such Contributor's behalf. Contributions do not include additions to the Program which: (i) are separate modules of software distributed in conjunction with the Program under their own license agreement, and (ii) are not derivative works of the Program."Contributor" means any person or entity that distributes the Program.@@ -28,24 +28,24 @@ where such changes and/or additions to the Program originate from and are distri2. GRANT OF RIGHTS-a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code form.+a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code form.b) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free patent license under Licensed Patents to make, use, sell, offer to sell, import and otherwise transfer the Contribution of such Contributor, if any, in source code and object code form. This patent license shall apply to the combination of the Contribution and the Program if, at the time the Contribution is added by the Contributor, such addition of the Contribution causes such combination to be covered by the Licensed Patents. The patent license shall not apply to any other combinations which include the Contribution. No hardware per se is licensed hereunder.-c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the Program, it is Recipient's responsibility to acquire that license before distributing the Program.-d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to grant the copyright license set forth in this Agreement.+c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the Program, it is Recipient's responsibility to acquire that license before distributing the Program.+d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to grant the copyright license set forth in this Agreement.3. REQUIREMENTSA Contributor may choose to distribute the Program in object code form under its own license agreement, provided that:-a) it complies with the terms and conditions of this Agreement; and-b) its license agreement:-i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and fitness for a particular purpose;+a) it complies with the terms and conditions of this Agreement; and+b) its license agreement:+i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and fitness for a particular purpose;ii) effectively excludes on behalf of all Contributors all liability for damages, including direct, indirect, special, incidental and consequential damages, such as lost profits;-iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any other party; and-iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it in a reasonable manner on or through a medium customarily used for software exchange.+iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any other party; and+iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it in a reasonable manner on or through a medium customarily used for software exchange.When the Program is made available in source code form:-a) it must be made available under this Agreement; and-b) a copy of this Agreement must be included with each copy of the Program.+a) it must be made available under this Agreement; and+b) a copy of this Agreement must be included with each copy of the Program.Contributors may not remove or alter any copyright notices contained within the Program.diff --git a/lucene/memory/src/test/org/apache/lucene/index/memory/TestMemoryIndexAgainstDirectory.java b/lucene/memory/src/test/org/apache/lucene/index/memory/TestMemoryIndexAgainstDirectory.javaindex 626286232c9..a9d83b0fa8c 100644--- a/lucene/memory/src/test/org/apache/lucene/index/memory/TestMemoryIndexAgainstDirectory.java+++ b/lucene/memory/src/test/org/apache/lucene/index/memory/TestMemoryIndexAgainstDirectory.java@@ -335,7 +335,6 @@ public class TestMemoryIndexAgainstDirectory extends BaseTokenStreamTestCase {reader.close();}- @SuppressWarnings("unused")private Allocator randomByteBlockAllocator() {if (random().nextBoolean()) {return new RecyclingByteBlockAllocator();@@ -378,7 +377,6 @@ public class TestMemoryIndexAgainstDirectory extends BaseTokenStreamTestCase {}// LUCENE-3831- @SuppressWarnings("resource")public void testNullPointerException() throws IOException {RegexpQuery regex = new RegexpQuery(new Term("field", "worl."));SpanQuery wrappedquery = new SpanMultiTermQueryWrapper<>(regex);@@ -392,7 +390,6 @@ public class TestMemoryIndexAgainstDirectory extends BaseTokenStreamTestCase {}// LUCENE-3831- @SuppressWarnings("resource")public void testPassesIfWrapped() throws IOException {RegexpQuery regex = new RegexpQuery(new Term("field", "worl."));SpanQuery wrappedquery = new SpanOrQuery(new SpanMultiTermQueryWrapper<>(regex));diff --git a/lucene/misc/src/java/org/apache/lucene/util/fst/UpToTwoPositiveIntOutputs.java b/lucene/misc/src/java/org/apache/lucene/util/fst/UpToTwoPositiveIntOutputs.javaindex 42ae747c572..327de1ff5f4 100644--- a/lucene/misc/src/java/org/apache/lucene/util/fst/UpToTwoPositiveIntOutputs.java+++ b/lucene/misc/src/java/org/apache/lucene/util/fst/UpToTwoPositiveIntOutputs.java@@ -83,7 +83,6 @@ public final class UpToTwoPositiveIntOutputs extends Outputs<Object> {}}- @SuppressWarnings("deprecation")private final static Long NO_OUTPUT = new Long(0);private final boolean doShare;diff --git a/lucene/misc/src/test/org/apache/lucene/search/similarity/TestLegacyBM25Similarity.java b/lucene/misc/src/test/org/apache/lucene/search/similarity/TestLegacyBM25Similarity.javaindex f3ab5468052..b3a0cd24ca1 100644--- a/lucene/misc/src/test/org/apache/lucene/search/similarity/TestLegacyBM25Similarity.java+++ b/lucene/misc/src/test/org/apache/lucene/search/similarity/TestLegacyBM25Similarity.java@@ -23,7 +23,6 @@ import org.apache.lucene.search.similarities.BM25Similarity;import org.apache.lucene.search.similarities.BaseSimilarityTestCase;import org.apache.lucene.search.similarities.Similarity;-@SuppressWarnings("deprecation")public class TestLegacyBM25Similarity extends BaseSimilarityTestCase {public void testIllegalK1() {diff --git a/lucene/queries/src/java/org/apache/lucene/queries/function/ValueSource.java b/lucene/queries/src/java/org/apache/lucene/queries/function/ValueSource.javaindex 7bbe82dbd6a..1ba35804002 100644--- a/lucene/queries/src/java/org/apache/lucene/queries/function/ValueSource.java+++ b/lucene/queries/src/java/org/apache/lucene/queries/function/ValueSource.java@@ -42,7 +42,6 @@ import org.apache.lucene.search.SortField;***/-@SuppressWarnings({"unchecked", "rawtypes", "deprecation"})public abstract class ValueSource {/**diff --git a/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/DocFreqValueSource.java b/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/DocFreqValueSource.javaindex c915293df28..e03e3160495 100644--- a/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/DocFreqValueSource.java+++ b/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/DocFreqValueSource.java@@ -144,7 +144,6 @@ public class DocFreqValueSource extends ValueSource {return name() + '(' + field + ',' + val + ')';}- @SuppressWarnings("rawtypes")@Overridepublic FunctionValues getValues(Map context, LeafReaderContext readerContext) throws IOException {IndexSearcher searcher = (IndexSearcher)context.get("searcher");@@ -152,7 +151,6 @@ public class DocFreqValueSource extends ValueSource {return new ConstIntDocValues(docfreq, this);}- @SuppressWarnings({"unchecked", "rawtypes"})@Overridepublic void createWeight(Map context, IndexSearcher searcher) throws IOException {context.put("searcher",searcher);diff --git a/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/MaxDocValueSource.java b/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/MaxDocValueSource.javaindex 2270978fbb9..ccd73269bed 100644--- a/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/MaxDocValueSource.java+++ b/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/MaxDocValueSource.java@@ -40,13 +40,11 @@ public class MaxDocValueSource extends ValueSource {return name() + "()";}- @SuppressWarnings({"unchecked", "rawtypes"})@Overridepublic void createWeight(Map context, IndexSearcher searcher) throws IOException {context.put("searcher",searcher);}- @SuppressWarnings("rawtypes")@Overridepublic FunctionValues getValues(Map context, LeafReaderContext readerContext) throws IOException {IndexSearcher searcher = (IndexSearcher)context.get("searcher");diff --git a/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/NormValueSource.java b/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/NormValueSource.javaindex 30bdc31af50..ffbb0c5fe4e 100644--- a/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/NormValueSource.java+++ b/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/NormValueSource.java@@ -54,13 +54,11 @@ public class NormValueSource extends ValueSource {return name() + '(' + field + ')';}- @SuppressWarnings({"unchecked", "rawtypes"})@Overridepublic void createWeight(Map context, IndexSearcher searcher) throws IOException {context.put("searcher",searcher);}- @SuppressWarnings("rawtypes")@Overridepublic FunctionValues getValues(Map context, LeafReaderContext readerContext) throws IOException {IndexSearcher searcher = (IndexSearcher)context.get("searcher");diff --git a/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/QueryValueSource.java b/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/QueryValueSource.javaindex b142c37b715..e535b55018f 100644--- a/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/QueryValueSource.java+++ b/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/QueryValueSource.java@@ -36,7 +36,6 @@ import org.apache.lucene.util.mutable.MutableValueFloat;/*** <code>QueryValueSource</code> returns the relevance score of the query*/-@SuppressWarnings({"unchecked", "rawtypes"})public class QueryValueSource extends ValueSource {final Query q;final float defVal;diff --git a/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/ScaleFloatFunction.java b/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/ScaleFloatFunction.javaindex 161d14297d7..38bd86a7a00 100644--- a/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/ScaleFloatFunction.java+++ b/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/ScaleFloatFunction.java@@ -59,7 +59,6 @@ public class ScaleFloatFunction extends ValueSource {float maxVal;}- @SuppressWarnings({"unchecked", "rawtypes"})private ScaleInfo createScaleInfo(Map context, LeafReaderContext readerContext) throws IOException {final List<LeafReaderContext> leaves = ReaderUtil.getTopLevelContext(readerContext).leaves();@@ -100,7 +99,6 @@ public class ScaleFloatFunction extends ValueSource {return scaleInfo;}- @SuppressWarnings("rawtypes")@Overridepublic FunctionValues getValues(Map context, LeafReaderContext readerContext) throws IOException {@@ -134,7 +132,6 @@ public class ScaleFloatFunction extends ValueSource {};}- @SuppressWarnings("rawtypes")@Overridepublic void createWeight(Map context, IndexSearcher searcher) throws IOException {source.createWeight(context, searcher);diff --git a/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/SumTotalTermFreqValueSource.java b/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/SumTotalTermFreqValueSource.javaindex 3f25d34ec08..716d3045397 100644--- a/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/SumTotalTermFreqValueSource.java+++ b/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/SumTotalTermFreqValueSource.java@@ -47,13 +47,11 @@ public class SumTotalTermFreqValueSource extends ValueSource {return name() + '(' + indexedField + ')';}- @SuppressWarnings("rawtypes")@Overridepublic FunctionValues getValues(Map context, LeafReaderContext readerContext) throws IOException {return (FunctionValues)context.get(this);}- @SuppressWarnings({"rawtypes", "unchecked"})@Overridepublic void createWeight(Map context, IndexSearcher searcher) throws IOException {long sumTotalTermFreq = 0;diff --git a/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/TotalTermFreqValueSource.java b/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/TotalTermFreqValueSource.javaindex 5e571213df4..5a69e42fcd2 100644--- a/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/TotalTermFreqValueSource.java+++ b/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/TotalTermFreqValueSource.java@@ -54,13 +54,11 @@ public class TotalTermFreqValueSource extends ValueSource {return name() + '(' + field + ',' + val + ')';}- @SuppressWarnings("rawtypes")@Overridepublic FunctionValues getValues(Map context, LeafReaderContext readerContext) throws IOException {return (FunctionValues)context.get(this);}- @SuppressWarnings({"rawtypes", "unchecked"})@Overridepublic void createWeight(Map context, IndexSearcher searcher) throws IOException {long totalTermFreq = 0;diff --git a/lucene/queries/src/test/org/apache/lucene/queries/payloads/TestPayloadCheckQuery.java b/lucene/queries/src/test/org/apache/lucene/queries/payloads/TestPayloadCheckQuery.javaindex 5b99e705f52..68691772593 100644--- a/lucene/queries/src/test/org/apache/lucene/queries/payloads/TestPayloadCheckQuery.java+++ b/lucene/queries/src/test/org/apache/lucene/queries/payloads/TestPayloadCheckQuery.java@@ -210,7 +210,6 @@ public class TestPayloadCheckQuery extends LuceneTestCase {assertFalse(query3.equals(query4));}- @SuppressWarnings({"unchecked", "rawtypes"})public void testRewrite() throws IOException {SpanMultiTermQueryWrapper fiv = new SpanMultiTermQueryWrapper(new WildcardQuery(new Term("field", "fiv*")));SpanMultiTermQueryWrapper hund = new SpanMultiTermQueryWrapper(new WildcardQuery(new Term("field", "hund*")));diff --git a/lucene/queryparser/src/java/org/apache/lucene/queryparser/classic/FastCharStream.java b/lucene/queryparser/src/java/org/apache/lucene/queryparser/classic/FastCharStream.javaindex f61285dd41f..d528111f4d1 100644--- a/lucene/queryparser/src/java/org/apache/lucene/queryparser/classic/FastCharStream.java+++ b/lucene/queryparser/src/java/org/apache/lucene/queryparser/classic/FastCharStream.java@@ -109,12 +109,7 @@ public final class FastCharStream implements CharStream {public final int getColumn() {return bufferStart + bufferPosition;}- /**- * @deprecated use getEndLine- * @see #getEndLine- */@Override- @Deprecatedpublic final int getLine() {return 1;}diff --git a/lucene/queryparser/src/java/org/apache/lucene/queryparser/classic/QueryParserBase.java b/lucene/queryparser/src/java/org/apache/lucene/queryparser/classic/QueryParserBase.javaindex 0ea7b37be04..7a03a3cefb9 100644--- a/lucene/queryparser/src/java/org/apache/lucene/queryparser/classic/QueryParserBase.java+++ b/lucene/queryparser/src/java/org/apache/lucene/queryparser/classic/QueryParserBase.java@@ -65,7 +65,6 @@ public abstract class QueryParserBase extends QueryBuilder implements CommonQuerprotected String field;int phraseSlop = 0;- @SuppressWarnings("deprecation")float fuzzyMinSim = FuzzyQuery.defaultMinSimilarity;int fuzzyPrefixLength = FuzzyQuery.defaultPrefixLength;Locale locale = Locale.getDefault();@@ -589,7 +588,6 @@ public abstract class QueryParserBase extends QueryBuilder implements CommonQuer* @param prefixLength prefix length* @return new FuzzyQuery Instance*/- @SuppressWarnings("deprecation")protected Query newFuzzyQuery(Term term, float minimumSimilarity, int prefixLength) {// FuzzyQuery doesn't yet allow constant score rewriteString text = term.text();diff --git a/lucene/queryparser/src/java/org/apache/lucene/queryparser/flexible/standard/builders/FuzzyQueryNodeBuilder.java b/lucene/queryparser/src/java/org/apache/lucene/queryparser/flexible/standard/builders/FuzzyQueryNodeBuilder.javaindex 81fe0d8bf8b..2575e802053 100644--- a/lucene/queryparser/src/java/org/apache/lucene/queryparser/flexible/standard/builders/FuzzyQueryNodeBuilder.java+++ b/lucene/queryparser/src/java/org/apache/lucene/queryparser/flexible/standard/builders/FuzzyQueryNodeBuilder.java@@ -36,7 +36,6 @@ public class FuzzyQueryNodeBuilder implements StandardQueryBuilder {FuzzyQueryNode fuzzyNode = (FuzzyQueryNode) queryNode;String text = fuzzyNode.getTextAsString();- @SuppressWarnings("deprecation")int numEdits = FuzzyQuery.floatToEdits(fuzzyNode.getSimilarity(),text.codePointCount(0, text.length()));diff --git a/lucene/queryparser/src/java/org/apache/lucene/queryparser/flexible/standard/config/FuzzyConfig.java b/lucene/queryparser/src/java/org/apache/lucene/queryparser/flexible/standard/config/FuzzyConfig.javaindex 1856e73ce24..b0ca671514f 100644--- a/lucene/queryparser/src/java/org/apache/lucene/queryparser/flexible/standard/config/FuzzyConfig.java+++ b/lucene/queryparser/src/java/org/apache/lucene/queryparser/flexible/standard/config/FuzzyConfig.java@@ -25,7 +25,6 @@ public class FuzzyConfig {private int prefixLength = FuzzyQuery.defaultPrefixLength;- @SuppressWarnings("deprecation")private float minSimilarity = FuzzyQuery.defaultMinSimilarity;public FuzzyConfig() {}diff --git a/lucene/queryparser/src/java/org/apache/lucene/queryparser/flexible/standard/parser/FastCharStream.java b/lucene/queryparser/src/java/org/apache/lucene/queryparser/flexible/standard/parser/FastCharStream.javaindex 86b205ade1e..ee0f9afe822 100644--- a/lucene/queryparser/src/java/org/apache/lucene/queryparser/flexible/standard/parser/FastCharStream.java+++ b/lucene/queryparser/src/java/org/apache/lucene/queryparser/flexible/standard/parser/FastCharStream.java@@ -106,21 +106,10 @@ public final class FastCharStream implements CharStream {}@Override- @Deprecated- /**- * Returns the column position of the character last read.- * @deprecated- * @see #getEndColumn- */public final int getColumn() {return bufferStart + bufferPosition;}@Override- @Deprecated- /**- * @deprecated- * @see #getEndLine- */public final int getLine() {return 1;}diff --git a/lucene/queryparser/src/java/org/apache/lucene/queryparser/surround/parser/FastCharStream.java b/lucene/queryparser/src/java/org/apache/lucene/queryparser/surround/parser/FastCharStream.javaindex 1f2436841a4..3a033f5046d 100644--- a/lucene/queryparser/src/java/org/apache/lucene/queryparser/surround/parser/FastCharStream.java+++ b/lucene/queryparser/src/java/org/apache/lucene/queryparser/surround/parser/FastCharStream.java@@ -105,21 +105,10 @@ public final class FastCharStream implements CharStream {}@Override- @Deprecated- /**- * @deprecated- * @see #getEndColumn- */public final int getColumn() {return bufferStart + bufferPosition;}@Override- @Deprecated- /**- * Returns the line number of the character last read.- * @deprecated- * @see #getEndLine- */public final int getLine() {return 1;}diff --git a/lucene/queryparser/src/java/org/apache/lucene/queryparser/xml/builders/FuzzyLikeThisQueryBuilder.java b/lucene/queryparser/src/java/org/apache/lucene/queryparser/xml/builders/FuzzyLikeThisQueryBuilder.javaindex a1e02af6f77..daf7354a73b 100644--- a/lucene/queryparser/src/java/org/apache/lucene/queryparser/xml/builders/FuzzyLikeThisQueryBuilder.java+++ b/lucene/queryparser/src/java/org/apache/lucene/queryparser/xml/builders/FuzzyLikeThisQueryBuilder.java@@ -33,7 +33,6 @@ import org.w3c.dom.NodeList;public class FuzzyLikeThisQueryBuilder implements QueryBuilder {private static final int DEFAULT_MAX_NUM_TERMS = 50;- @SuppressWarnings("deprecation")private static final float DEFAULT_MIN_SIMILARITY = FuzzyQuery.defaultMinSimilarity;private static final int DEFAULT_PREFIX_LENGTH = 1;private static final boolean DEFAULT_IGNORE_TF = false;diff --git a/lucene/queryparser/src/test/org/apache/lucene/queryparser/flexible/core/builders/TestQueryTreeBuilder.java b/lucene/queryparser/src/test/org/apache/lucene/queryparser/flexible/core/builders/TestQueryTreeBuilder.javaindex 2e132441d2a..be1eb2457ed 100644--- a/lucene/queryparser/src/test/org/apache/lucene/queryparser/flexible/core/builders/TestQueryTreeBuilder.java+++ b/lucene/queryparser/src/test/org/apache/lucene/queryparser/flexible/core/builders/TestQueryTreeBuilder.java@@ -27,9 +27,8 @@ import org.apache.lucene.queryparser.flexible.core.util.UnescapedCharSequence;import org.apache.lucene.util.LuceneTestCase;import org.junit.Test;-@SuppressWarnings("deprecation")public class TestQueryTreeBuilder extends LuceneTestCase {-+@Testpublic void testSetFieldBuilder() throws QueryNodeException {QueryTreeBuilder qtb = new QueryTreeBuilder();diff --git a/lucene/replicator/src/test/org/apache/lucene/replicator/ReplicatorTestCase.java b/lucene/replicator/src/test/org/apache/lucene/replicator/ReplicatorTestCase.javaindex 08ae407a968..c482ec27218 100644--- a/lucene/replicator/src/test/org/apache/lucene/replicator/ReplicatorTestCase.java+++ b/lucene/replicator/src/test/org/apache/lucene/replicator/ReplicatorTestCase.java@@ -51,7 +51,6 @@ public abstract class ReplicatorTestCase extends LuceneTestCase {* Returns a new {@link Server HTTP Server} instance. To obtain its port, use* {@link #serverPort(Server)}.*/- @SuppressWarnings("deprecation")public static synchronized Server newHttpServer(Handler handler) throws Exception {// if this property is true, then jetty will be configured to use SSL// leveraging the same system properties as java to specifydiff --git a/lucene/sandbox/src/java/org/apache/lucene/geo/SimpleWKTShapeParser.java b/lucene/sandbox/src/java/org/apache/lucene/geo/SimpleWKTShapeParser.javaindex c6dc6c2e007..17b595f7139 100644--- a/lucene/sandbox/src/java/org/apache/lucene/geo/SimpleWKTShapeParser.java+++ b/lucene/sandbox/src/java/org/apache/lucene/geo/SimpleWKTShapeParser.java@@ -114,7 +114,6 @@ public class SimpleWKTShapeParser {}/** Parses a list of points into latitude and longitude arraylists */- @SuppressWarnings("rawtypes")private static void parseCoordinates(StreamTokenizer stream, ArrayList lats, ArrayList lons)throws IOException, ParseException {boolean isOpenParen = false;@@ -138,7 +137,6 @@ public class SimpleWKTShapeParser {}/** parses a single coordinate, w/ optional 3rd dimension */- @SuppressWarnings({"unchecked", "rawtypes"})private static void parseCoordinate(StreamTokenizer stream, ArrayList lats, ArrayList lons)throws IOException, ParseException {lons.add(nextNumber(stream));@@ -154,8 +152,8 @@ public class SimpleWKTShapeParser {if (token.equals(EMPTY)) {return null;}- ArrayList<Double> lats = new ArrayList<>();- ArrayList<Double> lons = new ArrayList<>();+ ArrayList<Double> lats = new ArrayList();+ ArrayList<Double> lons = new ArrayList();parseCoordinates(stream, lats, lons);double[][] result = new double[lats.size()][2];for (int i = 0; i < lats.size(); ++i) {@@ -170,8 +168,8 @@ public class SimpleWKTShapeParser {if (token.equals(EMPTY)) {return null;}- ArrayList<Double> lats = new ArrayList<>();- ArrayList<Double> lons = new ArrayList<>();+ ArrayList<Double> lats = new ArrayList();+ ArrayList<Double> lons = new ArrayList();parseCoordinates(stream, lats, lons);return new Line(lats.stream().mapToDouble(i->i).toArray(), lons.stream().mapToDouble(i->i).toArray());}@@ -182,7 +180,7 @@ public class SimpleWKTShapeParser {if (token.equals(EMPTY)) {return null;}- ArrayList<Line> lines = new ArrayList<>();+ ArrayList<Line> lines = new ArrayList();lines.add(parseLine(stream));while (nextCloserOrComma(stream).equals(COMMA)) {lines.add(parseLine(stream));@@ -191,7 +189,6 @@ public class SimpleWKTShapeParser {}/** parses the hole of a polygon */- @SuppressWarnings({"rawtypes", "unchecked"})private static Polygon parsePolygonHole(StreamTokenizer stream) throws IOException, ParseException {ArrayList<Double> lats = new ArrayList();ArrayList<Double> lons = new ArrayList();@@ -200,7 +197,6 @@ public class SimpleWKTShapeParser {}/** parses a POLYGON */- @SuppressWarnings({"rawtypes", "unchecked"})private static Polygon parsePolygon(StreamTokenizer stream) throws IOException, ParseException {if (nextEmptyOrOpen(stream).equals(EMPTY)) {return null;@@ -226,7 +222,7 @@ public class SimpleWKTShapeParser {if (token.equals(EMPTY)) {return null;}- ArrayList<Polygon> polygons = new ArrayList<>();+ ArrayList<Polygon> polygons = new ArrayList();polygons.add(parsePolygon(stream));while (nextCloserOrComma(stream).equals(COMMA)) {polygons.add(parsePolygon(stream));diff --git a/lucene/spatial-extras/src/java/org/apache/lucene/spatial/SpatialStrategy.java b/lucene/spatial-extras/src/java/org/apache/lucene/spatial/SpatialStrategy.javaindex 79eb98ab569..215fa1d1a57 100644--- a/lucene/spatial-extras/src/java/org/apache/lucene/spatial/SpatialStrategy.java+++ b/lucene/spatial-extras/src/java/org/apache/lucene/spatial/SpatialStrategy.java@@ -133,7 +133,6 @@ public abstract class SpatialStrategy {* scores will be 1 for indexed points at the center of the query shape and as* low as ~0.1 at its furthest edges.*/- @SuppressWarnings("deprecation")public final DoubleValuesSource makeRecipDistanceValueSource(Shape queryShape) {Rectangle bbox = queryShape.getBoundingBox();double diagonalDist = ctx.getDistCalc().distance(diff --git a/lucene/spatial-extras/src/java/org/apache/lucene/spatial/bbox/BBoxValueSource.java b/lucene/spatial-extras/src/java/org/apache/lucene/spatial/bbox/BBoxValueSource.javaindex e31c5c13ab1..1a2525ed05b 100644--- a/lucene/spatial-extras/src/java/org/apache/lucene/spatial/bbox/BBoxValueSource.java+++ b/lucene/spatial-extras/src/java/org/apache/lucene/spatial/bbox/BBoxValueSource.java@@ -45,7 +45,6 @@ class BBoxValueSource extends ShapeValuesSource {return "bboxShape(" + strategy.getFieldName() + ")";}- @SuppressWarnings("deprecation")@Overridepublic ShapeValues getValues(LeafReaderContext readerContext) throws IOException {LeafReader reader = readerContext.reader();diff --git a/lucene/spatial-extras/src/java/org/apache/lucene/spatial/prefix/HeatmapFacetCounter.java b/lucene/spatial-extras/src/java/org/apache/lucene/spatial/prefix/HeatmapFacetCounter.javaindex 174e5695d74..6c5253e0d34 100644--- a/lucene/spatial-extras/src/java/org/apache/lucene/spatial/prefix/HeatmapFacetCounter.java+++ b/lucene/spatial-extras/src/java/org/apache/lucene/spatial/prefix/HeatmapFacetCounter.java@@ -88,7 +88,6 @@ public class HeatmapFacetCounter {* @param facetLevel the target depth (detail) of cells.* @param maxCells the maximum number of cells to return. If the cells exceed this count, an*/- @SuppressWarnings("deprecation")public static Heatmap calcFacets(PrefixTreeStrategy strategy, IndexReaderContext context, Bits topAcceptDocs,Shape inputShape, final int facetLevel, int maxCells) throws IOException {if (maxCells > (MAX_ROWS_OR_COLUMNS * MAX_ROWS_OR_COLUMNS)) {diff --git a/lucene/spatial-extras/src/java/org/apache/lucene/spatial/prefix/WithinPrefixTreeQuery.java b/lucene/spatial-extras/src/java/org/apache/lucene/spatial/prefix/WithinPrefixTreeQuery.javaindex 3958a67326d..f595f0e4639 100644--- a/lucene/spatial-extras/src/java/org/apache/lucene/spatial/prefix/WithinPrefixTreeQuery.java+++ b/lucene/spatial-extras/src/java/org/apache/lucene/spatial/prefix/WithinPrefixTreeQuery.java@@ -102,7 +102,6 @@ public class WithinPrefixTreeQuery extends AbstractVisitingPrefixTreeQuery {/** Returns a new shape that is larger than shape by at distErr.*///TODO move this generic code elsewhere? Spatial4j?- @SuppressWarnings("deprecation")protected Shape bufferShape(Shape shape, double distErr) {if (distErr <= 0)throw new IllegalArgumentException("distErr must be > 0");diff --git a/lucene/spatial-extras/src/java/org/apache/lucene/spatial/prefix/tree/PackedQuadPrefixTree.java b/lucene/spatial-extras/src/java/org/apache/lucene/spatial/prefix/tree/PackedQuadPrefixTree.javaindex 56adc72aa70..a7174a49eef 100644--- a/lucene/spatial-extras/src/java/org/apache/lucene/spatial/prefix/tree/PackedQuadPrefixTree.java+++ b/lucene/spatial-extras/src/java/org/apache/lucene/spatial/prefix/tree/PackedQuadPrefixTree.java@@ -84,7 +84,6 @@ public class PackedQuadPrefixTree extends QuadPrefixTree {return new PackedQuadCell(0x0L);}- @SuppressWarnings("deprecation")@Overridepublic Cell getCell(Point p, int level) {if (!robust) { // old method@@ -145,7 +144,6 @@ public class PackedQuadPrefixTree extends QuadPrefixTree {checkBattenbergNotRobustly(QUAD[3], x + w, y - h, level, matches, term, shape, maxLevel);}- @SuppressWarnings("deprecation")protected void checkBattenbergNotRobustly(byte quad, double cx, double cy, int level, List<Cell> matches,long term, Shape shape, int maxLevel) {// short-circuit if we find a match for the point (no need to continue recursion)diff --git a/lucene/spatial-extras/src/java/org/apache/lucene/spatial/prefix/tree/QuadPrefixTree.java b/lucene/spatial-extras/src/java/org/apache/lucene/spatial/prefix/tree/QuadPrefixTree.javaindex e4d72432eab..e060302c2a9 100644--- a/lucene/spatial-extras/src/java/org/apache/lucene/spatial/prefix/tree/QuadPrefixTree.java+++ b/lucene/spatial-extras/src/java/org/apache/lucene/spatial/prefix/tree/QuadPrefixTree.java@@ -138,7 +138,6 @@ public class QuadPrefixTree extends LegacyPrefixTree {return maxLevels;}- @SuppressWarnings("deprecation")@Overridepublic Cell getCell(Point p, int level) {if (!robust) { // old method@@ -209,7 +208,6 @@ public class QuadPrefixTree extends LegacyPrefixTree {// if we actually use the range property in the query, this could be useful}- @SuppressWarnings("deprecation")protected void checkBattenbergNotRobustly(char c,double cx,@@ -323,7 +321,6 @@ public class QuadPrefixTree extends LegacyPrefixTree {return shape;}- @SuppressWarnings("deprecation")protected Rectangle makeShape() {BytesRef token = getTokenBytesNoLeaf(null);double xmin = QuadPrefixTree.this.xmin;diff --git a/lucene/spatial-extras/src/java/org/apache/lucene/spatial/query/SpatialArgsParser.java b/lucene/spatial-extras/src/java/org/apache/lucene/spatial/query/SpatialArgsParser.javaindex c3bd3508afc..79ad7a94803 100644--- a/lucene/spatial-extras/src/java/org/apache/lucene/spatial/query/SpatialArgsParser.java+++ b/lucene/spatial-extras/src/java/org/apache/lucene/spatial/query/SpatialArgsParser.java@@ -112,7 +112,6 @@ public class SpatialArgsParser {args.setDistErr(readDouble(nameValPairs.remove(DIST_ERR)));}- @SuppressWarnings("deprecation")protected Shape parseShape(String str, SpatialContext ctx) throws ParseException {//return ctx.readShape(str);//still in Spatial4j 0.4 but will be deletedreturn ctx.readShapeFromWkt(str);diff --git a/lucene/spatial-extras/src/java/org/apache/lucene/spatial/spatial4j/Geo3dShapeFactory.java b/lucene/spatial-extras/src/java/org/apache/lucene/spatial/spatial4j/Geo3dShapeFactory.javaindex dbb557f449a..071c77517b6 100644--- a/lucene/spatial-extras/src/java/org/apache/lucene/spatial/spatial4j/Geo3dShapeFactory.java+++ b/lucene/spatial-extras/src/java/org/apache/lucene/spatial/spatial4j/Geo3dShapeFactory.java@@ -66,6 +66,7 @@ public class Geo3dShapeFactory implements S2ShapeFactory {private static final double DEFAULT_CIRCLE_ACCURACY = 1e-4;private double circleAccuracy = DEFAULT_CIRCLE_ACCURACY;+ @SuppressWarnings("unchecked")public Geo3dShapeFactory(SpatialContext context, SpatialContextFactory factory) {this.context = context;this.planetModel = ((Geo3dSpatialContextFactory) factory).planetModel;@@ -196,7 +197,6 @@ public class Geo3dShapeFactory implements S2ShapeFactory {}@Override- @Deprecated // use a builderpublic Shape lineString(List<Point> list, double distance) {LineStringBuilder builder = lineString();for (Point point : list) {@@ -207,7 +207,6 @@ public class Geo3dShapeFactory implements S2ShapeFactory {}@Override- @Deprecated // use a builderpublic <S extends Shape> ShapeCollection<S> multiShape(List<S> list) {throw new UnsupportedOperationException();}@@ -327,6 +326,7 @@ public class Geo3dShapeFactory implements S2ShapeFactory {}}+ @SuppressWarnings("unchecked")@Overridepublic Shape build() {GeoPolygonFactory.PolygonDescription description = new GeoPolygonFactory.PolygonDescription(points, polyHoles);diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/DistanceStrategyTest.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/DistanceStrategyTest.javaindex a39bafb9ef8..989252e3c6d 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/DistanceStrategyTest.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/DistanceStrategyTest.java@@ -36,7 +36,6 @@ import org.locationtech.spatial4j.context.SpatialContext;import org.locationtech.spatial4j.shape.Point;import org.locationtech.spatial4j.shape.Shape;-@SuppressWarnings("deprecation")public class DistanceStrategyTest extends StrategyTestCase {@ParametersFactory(argumentFormatting = "strategy=%s")public static Iterable<Object[]> parameters() {diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/PortedSolr3Test.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/PortedSolr3Test.javaindex d9d2124e7ba..f55daf64bb0 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/PortedSolr3Test.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/PortedSolr3Test.java@@ -40,7 +40,6 @@ import org.locationtech.spatial4j.shape.Shape;/*** Based off of Solr 3's SpatialFilterTest.*/-@SuppressWarnings("deprecation")public class PortedSolr3Test extends StrategyTestCase {@ParametersFactory(argumentFormatting = "strategy=%s")diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/QueryEqualsHashCodeTest.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/QueryEqualsHashCodeTest.javaindex 20188e81b08..f52ef2b444d 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/QueryEqualsHashCodeTest.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/QueryEqualsHashCodeTest.java@@ -102,13 +102,11 @@ public class QueryEqualsHashCodeTest extends LuceneTestCase {assertTrue(first.hashCode() != second.hashCode());}- @SuppressWarnings("deprecation")private SpatialArgs makeArgs1() {final Shape shape1 = ctx.makeRectangle(0, 0, 10, 10);return new SpatialArgs(predicate, shape1);}- @SuppressWarnings("deprecation")private SpatialArgs makeArgs2() {final Shape shape2 = ctx.makeRectangle(0, 0, 20, 20);return new SpatialArgs(predicate, shape2);diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/SpatialArgsTest.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/SpatialArgsTest.javaindex 7d19d0e05b4..da351fc857e 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/SpatialArgsTest.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/SpatialArgsTest.java@@ -23,7 +23,6 @@ import org.junit.Test;import org.locationtech.spatial4j.context.SpatialContext;import org.locationtech.spatial4j.shape.Shape;-@SuppressWarnings("deprecation")public class SpatialArgsTest extends LuceneTestCase {@Testdiff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/SpatialExample.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/SpatialExample.javaindex 1cad30f60e3..f810ab74438 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/SpatialExample.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/SpatialExample.java@@ -53,7 +53,6 @@ import org.locationtech.spatial4j.shape.Shape;* This class serves as example code to show how to use the Lucene spatial* module.*/-@SuppressWarnings("deprecation")public class SpatialExample extends LuceneTestCase {//Note: Test invoked via TestTestFramework.spatialExample()diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/SpatialTestCase.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/SpatialTestCase.javaindex ac802633628..55ad1d7e466 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/SpatialTestCase.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/SpatialTestCase.java@@ -119,7 +119,6 @@ public abstract class SpatialTestCase extends LuceneTestCase {}}- @SuppressWarnings("deprecation")protected Point randomPoint() {final Rectangle WB = ctx.getWorldBounds();return ctx.makePoint(@@ -131,7 +130,6 @@ public abstract class SpatialTestCase extends LuceneTestCase {return randomRectangle(ctx.getWorldBounds());}- @SuppressWarnings("deprecation")protected Rectangle randomRectangle(Rectangle bounds) {double[] xNewStartAndWidth = randomSubRange(bounds.getMinX(), bounds.getWidth());double xMin = xNewStartAndWidth[0];@@ -149,7 +147,6 @@ public abstract class SpatialTestCase extends LuceneTestCase {}/** Returns new minStart and new length that is inside the range specified by the arguments. */- @SuppressWarnings("deprecation")protected double[] randomSubRange(double boundStart, double boundLen) {if (boundLen >= 3 && usually()) { // typical// prefer integers for ease of debugability ... and prefer 1/16th of bounddiff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/SpatialTestData.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/SpatialTestData.javaindex 9dc81646587..06a68ce72e9 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/SpatialTestData.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/SpatialTestData.java@@ -41,7 +41,6 @@ public class SpatialTestData {* an "id", a "name" and the "shape". Empty lines and lines starting with a '#' are skipped.* The stream is closed.*/- @SuppressWarnings("deprecation")public static Iterator<SpatialTestData> getTestData(InputStream in, SpatialContext ctx) throws IOException {List<SpatialTestData> results = new ArrayList<>();BufferedReader bufInput = new BufferedReader(new InputStreamReader(in, StandardCharsets.UTF_8));diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/StrategyTestCase.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/StrategyTestCase.javaindex f44e995a2de..199ebcf01a7 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/StrategyTestCase.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/StrategyTestCase.java@@ -184,7 +184,6 @@ public abstract class StrategyTestCase extends SpatialTestCase {return strategy.makeQuery(q.args);}- @SuppressWarnings("deprecation")protected void adoc(String id, String shapeStr) throws IOException, ParseException {Shape shape = shapeStr==null ? null : ctx.readShapeFromWkt(shapeStr);addDocument(newDoc(id, shape));diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/bbox/TestBBoxStrategy.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/bbox/TestBBoxStrategy.javaindex b8219015613..210ab386fab 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/bbox/TestBBoxStrategy.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/bbox/TestBBoxStrategy.java@@ -36,7 +36,6 @@ import org.locationtech.spatial4j.shape.Rectangle;import org.locationtech.spatial4j.shape.Shape;import org.locationtech.spatial4j.shape.impl.RectangleImpl;-@SuppressWarnings("deprecation")public class TestBBoxStrategy extends RandomSpatialOpStrategyTestCase {@Overridediff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/composite/CompositeStrategyTest.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/composite/CompositeStrategyTest.javaindex f5e19b31bce..e74c2b5d074 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/composite/CompositeStrategyTest.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/composite/CompositeStrategyTest.java@@ -116,7 +116,6 @@ public class CompositeStrategyTest extends RandomSpatialOpStrategyTestCase {}//TODO move up- @SuppressWarnings("deprecation")private Shape randomCircle() {final Point point = randomPoint();//TODO pick using gaussiandiff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/DateNRStrategyTest.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/DateNRStrategyTest.javaindex 42821bb5f19..54296da040c 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/DateNRStrategyTest.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/DateNRStrategyTest.java@@ -38,7 +38,6 @@ public class DateNRStrategyTest extends RandomSpatialOpStrategyTestCase {long randomCalWindowMs;- @SuppressWarnings("deprecation")@Beforepublic void setUp() throws Exception {super.setUp();diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/HeatmapFacetCounterTest.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/HeatmapFacetCounterTest.javaindex edbfddb1fff..a38f5b6e7a7 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/HeatmapFacetCounterTest.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/HeatmapFacetCounterTest.java@@ -43,7 +43,6 @@ import org.locationtech.spatial4j.shape.impl.RectangleImpl;import static com.carrotsearch.randomizedtesting.RandomizedTest.atMost;import static com.carrotsearch.randomizedtesting.RandomizedTest.randomIntBetween;-@SuppressWarnings("deprecation")public class HeatmapFacetCounterTest extends StrategyTestCase {SpatialPrefixTree grid;diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/JtsPolygonTest.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/JtsPolygonTest.javaindex 974e14df06a..7d029f10e97 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/JtsPolygonTest.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/JtsPolygonTest.java@@ -37,7 +37,6 @@ import org.junit.Test;import java.text.ParseException;import java.util.HashMap;-@SuppressWarnings("deprecation")public class JtsPolygonTest extends StrategyTestCase {private static final double LUCENE_4464_distErrPct = SpatialArgs.DEFAULT_DISTERRPCT;//DEFAULT 2.5%diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/NumberRangeFacetsTest.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/NumberRangeFacetsTest.javaindex 680c26c3b04..9c128836f92 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/NumberRangeFacetsTest.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/NumberRangeFacetsTest.java@@ -45,7 +45,6 @@ import org.locationtech.spatial4j.shape.Shape;import static com.carrotsearch.randomizedtesting.RandomizedTest.randomInt;import static com.carrotsearch.randomizedtesting.RandomizedTest.randomIntBetween;-@SuppressWarnings("deprecation")public class NumberRangeFacetsTest extends StrategyTestCase {DateRangePrefixTree tree;diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/RandomSpatialOpFuzzyPrefixTreeTest.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/RandomSpatialOpFuzzyPrefixTreeTest.javaindex 60d9b13ef9a..c5b145f97c9 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/RandomSpatialOpFuzzyPrefixTreeTest.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/RandomSpatialOpFuzzyPrefixTreeTest.java@@ -63,7 +63,6 @@ import static org.locationtech.spatial4j.shape.SpatialRelation.WITHIN;/** Randomized PrefixTree test that considers the fuzziness of the* results introduced by grid approximation. */-@SuppressWarnings("deprecation")public class RandomSpatialOpFuzzyPrefixTreeTest extends StrategyTestCase {static final int ITERATIONS = 10;diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/RandomSpatialOpStrategyTestCase.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/RandomSpatialOpStrategyTestCase.javaindex 517cd7f2c9c..22c58393f5f 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/RandomSpatialOpStrategyTestCase.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/RandomSpatialOpStrategyTestCase.java@@ -34,7 +34,6 @@ import static com.carrotsearch.randomizedtesting.RandomizedTest.randomIntBetween/** Base test harness, ideally for SpatialStrategy impls that have exact results* (not grid approximated), hence "not fuzzy".*/-@SuppressWarnings("deprecation")public abstract class RandomSpatialOpStrategyTestCase extends StrategyTestCase {//Note: this is partially redundant with StrategyTestCase.runTestQuery & testOperationdiff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/TestRecursivePrefixTreeStrategy.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/TestRecursivePrefixTreeStrategy.javaindex 91967f87089..f852464ca19 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/TestRecursivePrefixTreeStrategy.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/TestRecursivePrefixTreeStrategy.java@@ -31,7 +31,6 @@ import java.io.IOException;import java.util.HashSet;import java.util.Set;-@SuppressWarnings("deprecation")public class TestRecursivePrefixTreeStrategy extends StrategyTestCase {private int maxLength;diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/TestTermQueryPrefixGridStrategy.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/TestTermQueryPrefixGridStrategy.javaindex def1aa1f607..fc131c5d788 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/TestTermQueryPrefixGridStrategy.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/TestTermQueryPrefixGridStrategy.java@@ -30,9 +30,9 @@ import org.junit.Test;import java.io.IOException;import java.util.Arrays;+public class TestTermQueryPrefixGridStrategy extends SpatialTestCase {- @SuppressWarnings("deprecation")@Testpublic void testNGramPrefixGridLosAngeles() throws IOException {SpatialContext ctx = SpatialContext.GEO;diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/tree/SpatialPrefixTreeTest.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/tree/SpatialPrefixTreeTest.javaindex e1dfdc4252e..cc63b5e17ca 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/tree/SpatialPrefixTreeTest.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/prefix/tree/SpatialPrefixTreeTest.java@@ -79,7 +79,6 @@ public class SpatialPrefixTreeTest extends SpatialTestCase {* A PrefixTree pruning optimization gone bad, applicable when optimize=true.* See <a href="https://issues.apache.org/jira/browse/LUCENE-4770">LUCENE-4770</a>.*/- @SuppressWarnings("deprecation")@Testpublic void testBadPrefixTreePrune() throws Exception {diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/spatial4j/Geo3dRptTest.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/spatial4j/Geo3dRptTest.javaindex 07f49099c61..6ec773b8faf 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/spatial4j/Geo3dRptTest.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/spatial4j/Geo3dRptTest.java@@ -46,7 +46,6 @@ import org.locationtech.spatial4j.shape.Shape;import static org.locationtech.spatial4j.distance.DistanceUtils.DEGREES_TO_RADIANS;-@SuppressWarnings("deprecation")public class Geo3dRptTest extends RandomSpatialOpStrategyTestCase {private PlanetModel planetModel;diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/spatial4j/Geo3dShapeSphereModelRectRelationTest.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/spatial4j/Geo3dShapeSphereModelRectRelationTest.javaindex 5012803c095..bf152b7fdfb 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/spatial4j/Geo3dShapeSphereModelRectRelationTest.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/spatial4j/Geo3dShapeSphereModelRectRelationTest.java@@ -66,7 +66,6 @@ public class Geo3dShapeSphereModelRectRelationTest extends ShapeRectRelationTest}- @SuppressWarnings({"unchecked", "rawtypes", "deprecation"})@Testpublic void testFailure2_LUCENE6475() {GeoCircle geo3dCircle = GeoCircleFactory.makeGeoCircle(planetModel, 1.6282053147165243E-4 * RADIANS_PER_DEGREE,diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/spatial4j/RandomizedShapeTestCase.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/spatial4j/RandomizedShapeTestCase.javaindex 0c90b31ff9c..0c18f5d7dde 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/spatial4j/RandomizedShapeTestCase.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/spatial4j/RandomizedShapeTestCase.java@@ -36,7 +36,6 @@ import static com.carrotsearch.randomizedtesting.RandomizedTest.*;* A base test class with utility methods to help test shapes.* Extends from RandomizedTest.*/-@SuppressWarnings("deprecation")public abstract class RandomizedShapeTestCase extends LuceneTestCase {protected static final double EPS = 10e-9;@@ -56,6 +55,7 @@ public abstract class RandomizedShapeTestCase extends LuceneTestCase {this.ctx = ctx;}+ @SuppressWarnings("unchecked")public static void checkShapesImplementEquals( Class<?>[] classes ) {for( Class<?> clazz : classes ) {try {diff --git a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/vector/TestPointVectorStrategy.java b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/vector/TestPointVectorStrategy.javaindex 320bb7415ef..901594ef749 100644--- a/lucene/spatial-extras/src/test/org/apache/lucene/spatial/vector/TestPointVectorStrategy.java+++ b/lucene/spatial-extras/src/test/org/apache/lucene/spatial/vector/TestPointVectorStrategy.java@@ -33,7 +33,6 @@ import org.locationtech.spatial4j.context.SpatialContext;import org.locationtech.spatial4j.shape.Circle;import org.locationtech.spatial4j.shape.Point;-@SuppressWarnings("deprecation")public class TestPointVectorStrategy extends StrategyTestCase {@Beforediff --git a/lucene/suggest/src/java/org/apache/lucene/search/suggest/jaspell/JaspellLookup.java b/lucene/suggest/src/java/org/apache/lucene/search/suggest/jaspell/JaspellLookup.javaindex b816773e5d4..948ebeb0151 100644--- a/lucene/suggest/src/java/org/apache/lucene/search/suggest/jaspell/JaspellLookup.java+++ b/lucene/suggest/src/java/org/apache/lucene/search/suggest/jaspell/JaspellLookup.java@@ -23,6 +23,7 @@ import java.util.Set;import org.apache.lucene.search.suggest.InputIterator;import org.apache.lucene.search.suggest.Lookup;+import org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode;import org.apache.lucene.store.DataInput;import org.apache.lucene.store.DataOutput;import org.apache.lucene.util.Accountable;@@ -38,7 +39,6 @@ import org.apache.lucene.util.CharsRefBuilder;* @deprecated Migrate to one of the newer suggesters which are much more RAM efficient.*/@Deprecated-@SuppressWarnings("deprecation")public class JaspellLookup extends Lookup implements Accountable {JaspellTernarySearchTrie trie = new JaspellTernarySearchTrie();private boolean usePrefix = true;@@ -140,52 +140,52 @@ public class JaspellLookup extends Lookup implements Accountable {private static final byte HI_KID = 0x04;private static final byte HAS_VALUE = 0x08;- private void readRecursively(DataInput in, org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode node) throws IOException {+ private void readRecursively(DataInput in, TSTNode node) throws IOException {node.splitchar = in.readString().charAt(0);byte mask = in.readByte();if ((mask & HAS_VALUE) != 0) {node.data = Long.valueOf(in.readLong());}if ((mask & LO_KID) != 0) {- org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode kid = new org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode('\0', node);- node.relatives[org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode.LOKID] = kid;+ TSTNode kid = new TSTNode('\0', node);+ node.relatives[TSTNode.LOKID] = kid;readRecursively(in, kid);}if ((mask & EQ_KID) != 0) {- org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode kid = new org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode('\0', node);- node.relatives[org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode.EQKID] = kid;+ TSTNode kid = new TSTNode('\0', node);+ node.relatives[TSTNode.EQKID] = kid;readRecursively(in, kid);}if ((mask & HI_KID) != 0) {- org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode kid = new org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode('\0', node);- node.relatives[org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode.HIKID] = kid;+ TSTNode kid = new TSTNode('\0', node);+ node.relatives[TSTNode.HIKID] = kid;readRecursively(in, kid);}}- private void writeRecursively(DataOutput out, org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode node) throws IOException {+ private void writeRecursively(DataOutput out, TSTNode node) throws IOException {if (node == null) {return;}out.writeString(new String(new char[] {node.splitchar}, 0, 1));byte mask = 0;- if (node.relatives[org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode.LOKID] != null) mask |= LO_KID;- if (node.relatives[org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode.EQKID] != null) mask |= EQ_KID;- if (node.relatives[org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode.HIKID] != null) mask |= HI_KID;+ if (node.relatives[TSTNode.LOKID] != null) mask |= LO_KID;+ if (node.relatives[TSTNode.EQKID] != null) mask |= EQ_KID;+ if (node.relatives[TSTNode.HIKID] != null) mask |= HI_KID;if (node.data != null) mask |= HAS_VALUE;out.writeByte(mask);if (node.data != null) {out.writeLong(((Number)node.data).longValue());}- writeRecursively(out, node.relatives[org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode.LOKID]);- writeRecursively(out, node.relatives[org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode.EQKID]);- writeRecursively(out, node.relatives[org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode.HIKID]);+ writeRecursively(out, node.relatives[TSTNode.LOKID]);+ writeRecursively(out, node.relatives[TSTNode.EQKID]);+ writeRecursively(out, node.relatives[TSTNode.HIKID]);}@Overridepublic boolean store(DataOutput output) throws IOException {output.writeVLong(count);- org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode root = trie.getRoot();+ TSTNode root = trie.getRoot();if (root == null) { // empty treereturn false;}@@ -196,7 +196,7 @@ public class JaspellLookup extends Lookup implements Accountable {@Overridepublic boolean load(DataInput input) throws IOException {count = input.readVLong();- org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode root = new org.apache.lucene.search.suggest.jaspell.JaspellTernarySearchTrie.TSTNode('\0', null);+ TSTNode root = new TSTNode('\0', null);readRecursively(input, root);trie.setRoot(root);return true;diff --git a/lucene/suggest/src/test/org/apache/lucene/search/spell/TestWordBreakSpellChecker.java b/lucene/suggest/src/test/org/apache/lucene/search/spell/TestWordBreakSpellChecker.javaindex cc2dbadf027..35e8245ac8b 100644--- a/lucene/suggest/src/test/org/apache/lucene/search/spell/TestWordBreakSpellChecker.java+++ b/lucene/suggest/src/test/org/apache/lucene/search/spell/TestWordBreakSpellChecker.java@@ -38,7 +38,6 @@ import org.apache.lucene.util.IOUtils;import org.apache.lucene.util.LuceneTestCase;import org.apache.lucene.util.TestUtil;-@SuppressWarnings("deprecation")public class TestWordBreakSpellChecker extends LuceneTestCase {private Directory dir;private Analyzer analyzer;diff --git a/lucene/suggest/src/test/org/apache/lucene/search/suggest/LookupBenchmarkTest.java b/lucene/suggest/src/test/org/apache/lucene/search/suggest/LookupBenchmarkTest.javaindex a38a33343e2..9f9190a5773 100644--- a/lucene/suggest/src/test/org/apache/lucene/search/suggest/LookupBenchmarkTest.java+++ b/lucene/suggest/src/test/org/apache/lucene/search/suggest/LookupBenchmarkTest.java@@ -40,6 +40,7 @@ import org.apache.lucene.search.suggest.analyzing.FreeTextSuggester;import org.apache.lucene.search.suggest.analyzing.FuzzySuggester;import org.apache.lucene.search.suggest.fst.FSTCompletionLookup;import org.apache.lucene.search.suggest.fst.WFSTCompletionLookup;+import org.apache.lucene.search.suggest.jaspell.JaspellLookup;import org.apache.lucene.search.suggest.tst.TSTLookup;import org.apache.lucene.store.Directory;import org.apache.lucene.store.FSDirectory;@@ -52,12 +53,12 @@ import org.junit.Ignore;*/@Ignore("COMMENT ME TO RUN BENCHMARKS!")public class LookupBenchmarkTest extends LuceneTestCase {- @SuppressWarnings("deprecation")+ @SuppressWarnings("unchecked")private final List<Class<? extends Lookup>> benchmarkClasses = Arrays.asList(FuzzySuggester.class,AnalyzingSuggester.class,AnalyzingInfixSuggester.class,- org.apache.lucene.search.suggest.jaspell.JaspellLookup.class,+ JaspellLookup.class,TSTLookup.class,FSTCompletionLookup.class,WFSTCompletionLookup.class,diff --git a/lucene/suggest/src/test/org/apache/lucene/search/suggest/PersistenceTest.java b/lucene/suggest/src/test/org/apache/lucene/search/suggest/PersistenceTest.javaindex c060a1c7876..fd5b558de4e 100644--- a/lucene/suggest/src/test/org/apache/lucene/search/suggest/PersistenceTest.java+++ b/lucene/suggest/src/test/org/apache/lucene/search/suggest/PersistenceTest.java@@ -51,7 +51,6 @@ public class PersistenceTest extends LuceneTestCase {runTest(TSTLookup.class, true);}- @SuppressWarnings("deprecation")public void testJaspellPersistence() throws Exception {runTest(JaspellLookup.class, true);}diff --git a/lucene/test-framework/src/java/org/apache/lucene/search/QueryUtils.java b/lucene/test-framework/src/java/org/apache/lucene/search/QueryUtils.javaindex d4ec009a95e..cdbac777846 100644--- a/lucene/test-framework/src/java/org/apache/lucene/search/QueryUtils.java+++ b/lucene/test-framework/src/java/org/apache/lucene/search/QueryUtils.java@@ -20,7 +20,7 @@ import java.io.IOException;import java.util.List;import java.util.Random;-import org.junit.Assert;+import junit.framework.Assert;import org.apache.lucene.index.BinaryDocValues;import org.apache.lucene.index.FieldInfos;import org.apache.lucene.index.Fields;@@ -40,9 +40,9 @@ import org.apache.lucene.util.Bits;import org.apache.lucene.util.LuceneTestCase;import org.apache.lucene.util.Version;-import static org.junit.Assert.assertEquals;-import static org.junit.Assert.assertFalse;-import static org.junit.Assert.assertTrue;+import static junit.framework.Assert.assertEquals;+import static junit.framework.Assert.assertFalse;+import static junit.framework.Assert.assertTrue;/*** Utility class for sanity-checking queries.diff --git a/lucene/test-framework/src/java/org/apache/lucene/util/fst/FSTTester.java b/lucene/test-framework/src/java/org/apache/lucene/util/fst/FSTTester.javaindex cc0faae5ade..590841d8e78 100644--- a/lucene/test-framework/src/java/org/apache/lucene/util/fst/FSTTester.java+++ b/lucene/test-framework/src/java/org/apache/lucene/util/fst/FSTTester.java@@ -341,7 +341,6 @@ public class FSTTester<T> {}// FST is complete- @SuppressWarnings("deprecation")private void verifyUnPruned(int inputMode, FST<T> fst) throws IOException {final FST<Long> fstLong;diff --git a/lucene/test-framework/src/test/org/apache/lucene/search/TestBaseExplanationTestCase.java b/lucene/test-framework/src/test/org/apache/lucene/search/TestBaseExplanationTestCase.javaindex 4e7adf1a4da..2f0f067c513 100644--- a/lucene/test-framework/src/test/org/apache/lucene/search/TestBaseExplanationTestCase.java+++ b/lucene/test-framework/src/test/org/apache/lucene/search/TestBaseExplanationTestCase.java@@ -20,6 +20,9 @@ import java.io.IOException;import org.apache.lucene.index.LeafReaderContext;import org.apache.lucene.index.Term;++import junit.framework.AssertionFailedError;+/*** Tests that the {@link BaseExplanationTestCase} helper code, as well as* {@link CheckHits#checkNoMatchExplanations} are checking what they are suppose to.@@ -27,12 +30,12 @@ import org.apache.lucene.index.Term;public class TestBaseExplanationTestCase extends BaseExplanationTestCase {public void testQueryNoMatchWhenExpected() throws Exception {- expectThrows(AssertionError.class, () -> {+ expectThrows(AssertionFailedError.class, () -> {qtest(new TermQuery(new Term(FIELD, "BOGUS")), new int[] { 3 /* none */ });});}public void testQueryMatchWhenNotExpected() throws Exception {- expectThrows(AssertionError.class, () -> {+ expectThrows(AssertionFailedError.class, () -> {qtest(new TermQuery(new Term(FIELD, "w1")), new int[] { 0, 1 /*, 2, 3 */ });});}@@ -42,7 +45,7 @@ public class TestBaseExplanationTestCase extends BaseExplanationTestCase {qtest(new TermQuery(new Term(FIELD, "zz")), new int[] { 1, 3 });// ensure when the Explanations are broken, we get an error about those matches- expectThrows(AssertionError.class, () -> {+ expectThrows(AssertionFailedError.class, () -> {qtest(new BrokenExplainTermQuery(new Term(FIELD, "zz"), false, true), new int[] { 1, 3 });});@@ -53,7 +56,7 @@ public class TestBaseExplanationTestCase extends BaseExplanationTestCase {qtest(new TermQuery(new Term(FIELD, "zz")), new int[] { 1, 3 });// ensure when the Explanations are broken, we get an error about the non matches- expectThrows(AssertionError.class, () -> {+ expectThrows(AssertionFailedError.class, () -> {CheckHits.checkNoMatchExplanations(new BrokenExplainTermQuery(new Term(FIELD, "zz"), true, false),FIELD, searcher, new int[] { 1, 3 });});diff --git a/lucene/test-framework/src/test/org/apache/lucene/util/TestExceptionInBeforeClassHooks.java b/lucene/test-framework/src/test/org/apache/lucene/util/TestExceptionInBeforeClassHooks.javaindex bc9e89af61f..bd99b4bea64 100644--- a/lucene/test-framework/src/test/org/apache/lucene/util/TestExceptionInBeforeClassHooks.java+++ b/lucene/test-framework/src/test/org/apache/lucene/util/TestExceptionInBeforeClassHooks.java@@ -20,7 +20,7 @@ import java.util.*;import java.util.regex.Matcher;import java.util.regex.Pattern;-import org.junit.Assert;+import junit.framework.Assert;import org.junit.Before;import org.junit.BeforeClass;diff --git a/solr/CHANGES.txt b/solr/CHANGES.txtindex ccacb67e649..b8f47129fe7 100644--- a/solr/CHANGES.txt+++ b/solr/CHANGES.txt@@ -149,9 +149,6 @@ Improvements* SOLR-13905: Make findRequestType in AuditEvent more robust (janhoy)-* SOLR-13952: Separate out Gradle-specific code from other (mostly test) changes and commit- separately (Erick Erickson)-* SOLR-13961: When using partial/atomic updates to remove child documents, we now support setting to null oran empty list as equivalent to the "remove" command. (Thomas Wöckinger)diff --git a/solr/contrib/analysis-extras/src/java/org/apache/solr/schema/ICUCollationField.java b/solr/contrib/analysis-extras/src/java/org/apache/solr/schema/ICUCollationField.javaindex 41d6a796bd9..f723a25b24c 100644--- a/solr/contrib/analysis-extras/src/java/org/apache/solr/schema/ICUCollationField.java+++ b/solr/contrib/analysis-extras/src/java/org/apache/solr/schema/ICUCollationField.java@@ -96,7 +96,6 @@ public class ICUCollationField extends FieldType {/*** Setup the field according to the provided parameters*/- @SuppressWarnings("deprecation")private void setup(ResourceLoader loader, Map<String,String> args) {String custom = args.remove("custom");String localeID = args.remove("locale");@@ -198,7 +197,6 @@ public class ICUCollationField extends FieldType {* Read custom rules from a file, and create a RuleBasedCollator* The file cannot support comments, as # might be in the rules!*/- @SuppressWarnings("deprecation")static Collator createFromRules(String fileName, ResourceLoader loader) {InputStream input = null;try {diff --git a/solr/contrib/analysis-extras/src/test/org/apache/solr/schema/TestICUCollationField.java b/solr/contrib/analysis-extras/src/test/org/apache/solr/schema/TestICUCollationField.javaindex 0916fe83233..f164080a7b8 100644--- a/solr/contrib/analysis-extras/src/test/org/apache/solr/schema/TestICUCollationField.java+++ b/solr/contrib/analysis-extras/src/test/org/apache/solr/schema/TestICUCollationField.java@@ -62,7 +62,6 @@ public class TestICUCollationField extends SolrTestCaseJ4 {* look out for jvm differences with collation).* So it's preferable to create this file on-the-fly.*/- @SuppressWarnings("deprecation")public static String setupSolrHome() throws Exception {String tmpFile = createTempDir().toFile().getAbsolutePath();// make data and conf dirsdiff --git a/solr/contrib/analytics/src/java/org/apache/solr/analytics/ExpressionFactory.java b/solr/contrib/analytics/src/java/org/apache/solr/analytics/ExpressionFactory.javaindex 29ce7ed45a6..9407d1dd354 100644--- a/solr/contrib/analytics/src/java/org/apache/solr/analytics/ExpressionFactory.java+++ b/solr/contrib/analytics/src/java/org/apache/solr/analytics/ExpressionFactory.java@@ -465,7 +465,6 @@ public class ExpressionFactory {* @return an analytics representation of the field* @throws SolrException if the field is not supported by the analytics framework*/- @SuppressWarnings("deprecation")private AnalyticsField createField(SchemaField field) throws SolrException {String fieldName = field.getName();if (fields.containsKey(fieldName)) {@@ -578,7 +577,6 @@ public class ExpressionFactory {* @return an array of param strings* @throws SolrException if the function has incorrect syntax*/- @SuppressWarnings("unused")private static String[] getFunctionParams(String function) throws SolrException {return getParams(function, null, null);}diff --git a/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/DateFieldsTest.java b/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/DateFieldsTest.javaindex 8947550a430..fb86738acc2 100644--- a/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/DateFieldsTest.java+++ b/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/DateFieldsTest.java@@ -26,7 +26,6 @@ import org.junit.Test;public class DateFieldsTest extends AbstractAnalyticsFieldTest {- @SuppressWarnings("deprecation")@Testpublic void expressionFactoryCreationTest() {ExpressionFactory fact = getExpressionFactory();@@ -69,7 +68,6 @@ public class DateFieldsTest extends AbstractAnalyticsFieldTest {checkSingleFieldValues(singleDates, values, missing);}- @SuppressWarnings("deprecation")@Testpublic void multiValuedTrieDateTest() throws IOException {DateMultiTrieField valueField = new DateMultiTrieField("date_dtm_t");diff --git a/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/DoubleFieldsTest.java b/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/DoubleFieldsTest.javaindex b4c01809172..e046f59f6cd 100644--- a/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/DoubleFieldsTest.java+++ b/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/DoubleFieldsTest.java@@ -26,7 +26,6 @@ import org.junit.Test;public class DoubleFieldsTest extends AbstractAnalyticsFieldTest {- @SuppressWarnings("deprecation")@Testpublic void expressionFactoryCreationTest() {ExpressionFactory fact = getExpressionFactory();@@ -69,7 +68,6 @@ public class DoubleFieldsTest extends AbstractAnalyticsFieldTest {checkSingleFieldValues(singleDoubles, values, missing);}- @SuppressWarnings("deprecation")@Testpublic void multiValuedTrieDoubleTest() throws IOException {DoubleMultiTrieField valueField = new DoubleMultiTrieField("double_dm_t");diff --git a/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/FloatFieldsTest.java b/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/FloatFieldsTest.javaindex ac39ab03473..bba6d465bb4 100644--- a/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/FloatFieldsTest.java+++ b/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/FloatFieldsTest.java@@ -26,7 +26,6 @@ import org.junit.Test;public class FloatFieldsTest extends AbstractAnalyticsFieldTest {- @SuppressWarnings("deprecation")@Testpublic void expressionFactoryCreationTest() {ExpressionFactory fact = getExpressionFactory();@@ -69,7 +68,6 @@ public class FloatFieldsTest extends AbstractAnalyticsFieldTest {checkSingleFieldValues(singleFloats, values, missing);}- @SuppressWarnings("deprecation")@Testpublic void multiValuedTrieFloatTest() throws IOException {FloatMultiTrieField valueField = new FloatMultiTrieField("float_fm_t");diff --git a/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/IntFieldsTest.java b/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/IntFieldsTest.javaindex ba60204bda8..ec52f681431 100644--- a/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/IntFieldsTest.java+++ b/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/IntFieldsTest.java@@ -26,7 +26,6 @@ import org.junit.Test;public class IntFieldsTest extends AbstractAnalyticsFieldTest {- @SuppressWarnings("deprecation")@Testpublic void expressionFactoryCreationTest() {ExpressionFactory fact = getExpressionFactory();@@ -69,7 +68,6 @@ public class IntFieldsTest extends AbstractAnalyticsFieldTest {checkSingleFieldValues(singleInts, values, missing);}- @SuppressWarnings("deprecation")@Testpublic void multiValuedTrieIntTest() throws IOException {IntMultiTrieField valueField = new IntMultiTrieField("int_im_t");diff --git a/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/LongFieldsTest.java b/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/LongFieldsTest.javaindex 960fcf4c2e3..6c190db52da 100644--- a/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/LongFieldsTest.java+++ b/solr/contrib/analytics/src/test/org/apache/solr/analytics/function/field/LongFieldsTest.java@@ -26,7 +26,6 @@ import org.junit.Test;public class LongFieldsTest extends AbstractAnalyticsFieldTest {- @SuppressWarnings("deprecation")@Testpublic void expressionFactoryCreationTest() {ExpressionFactory fact = getExpressionFactory();@@ -69,7 +68,6 @@ public class LongFieldsTest extends AbstractAnalyticsFieldTest {checkSingleFieldValues(singleLongs, values, missing);}- @SuppressWarnings("deprecation")@Testpublic void multiValuedTrieLongTest() throws IOException {LongMultiTrieField valueField = new LongMultiTrieField("long_lm_t");diff --git a/solr/contrib/analytics/src/test/org/apache/solr/analytics/legacy/facet/LegacyFieldFacetTest.java b/solr/contrib/analytics/src/test/org/apache/solr/analytics/legacy/facet/LegacyFieldFacetTest.javaindex f1d468cbec5..d3943808b56 100644--- a/solr/contrib/analytics/src/test/org/apache/solr/analytics/legacy/facet/LegacyFieldFacetTest.java+++ b/solr/contrib/analytics/src/test/org/apache/solr/analytics/legacy/facet/LegacyFieldFacetTest.java@@ -938,6 +938,7 @@ public class LegacyFieldFacetTest extends LegacyAbstractAnalyticsFacetTest{assertEquals(getRawResponse(),stringLong,stringLongTest);}+ @SuppressWarnings("unchecked")@Testpublic void missingTest() throws Exception {//Int Date@@ -1056,7 +1057,6 @@ public class LegacyFieldFacetTest extends LegacyAbstractAnalyticsFacetTest{}}- @SuppressWarnings({"unchecked", "rawtypes"})public static void assertEquals(String mes, Object actual, Object expected) {Collections.sort((List<Comparable>) actual);Collections.sort((List<Comparable>) expected);diff --git a/solr/contrib/clustering/src/java/org/apache/solr/handler/clustering/carrot2/CarrotClusteringEngine.java b/solr/contrib/clustering/src/java/org/apache/solr/handler/clustering/carrot2/CarrotClusteringEngine.javaindex cb72bbe4eda..b75b8c6deed 100644--- a/solr/contrib/clustering/src/java/org/apache/solr/handler/clustering/carrot2/CarrotClusteringEngine.java+++ b/solr/contrib/clustering/src/java/org/apache/solr/handler/clustering/carrot2/CarrotClusteringEngine.java@@ -286,7 +286,6 @@ public class CarrotClusteringEngine extends SearchClusteringEngine {/*** Prepares Carrot2 documents for clustering.*/- @SuppressWarnings("deprecation")private List<Document> getDocuments(SolrDocumentList solrDocList, Map<SolrDocument, Integer> docIds,Query query, final SolrQueryRequest sreq) throws IOException {SolrHighlighter highlighter = null;diff --git a/solr/contrib/dataimporthandler-extras/src/java/org/apache/solr/handler/dataimport/MailEntityProcessor.java b/solr/contrib/dataimporthandler-extras/src/java/org/apache/solr/handler/dataimport/MailEntityProcessor.javaindex 45ce4f6ba46..f19a4ca9ffd 100644--- a/solr/contrib/dataimporthandler-extras/src/java/org/apache/solr/handler/dataimport/MailEntityProcessor.java+++ b/solr/contrib/dataimporthandler-extras/src/java/org/apache/solr/handler/dataimport/MailEntityProcessor.java@@ -52,7 +52,6 @@ import com.sun.mail.gimap.GmailRawSearchTerm;** @since solr 1.4*/-@SuppressWarnings("unchecked")public class MailEntityProcessor extends EntityProcessorBase {private static final SimpleDateFormat sinceDateParser =diff --git a/solr/contrib/dataimporthandler-extras/src/java/org/apache/solr/handler/dataimport/TikaEntityProcessor.java b/solr/contrib/dataimporthandler-extras/src/java/org/apache/solr/handler/dataimport/TikaEntityProcessor.javaindex 1245dd8e104..875032b5a1f 100644--- a/solr/contrib/dataimporthandler-extras/src/java/org/apache/solr/handler/dataimport/TikaEntityProcessor.java+++ b/solr/contrib/dataimporthandler-extras/src/java/org/apache/solr/handler/dataimport/TikaEntityProcessor.java@@ -124,7 +124,6 @@ public class TikaEntityProcessor extends EntityProcessorBase {spatialMetadataField = context.getResolvedEntityAttribute("spatialMetadataField");}- @SuppressWarnings({"unchecked", "deprecation"})@Overridepublic Map<String, Object> nextRow() {if(done) return null;diff --git a/solr/contrib/dataimporthandler-extras/src/test/org/apache/solr/handler/dataimport/TestMailEntityProcessor.java b/solr/contrib/dataimporthandler-extras/src/test/org/apache/solr/handler/dataimport/TestMailEntityProcessor.javaindex fa5bfe0112a..0b00be60557 100644--- a/solr/contrib/dataimporthandler-extras/src/test/org/apache/solr/handler/dataimport/TestMailEntityProcessor.java+++ b/solr/contrib/dataimporthandler-extras/src/test/org/apache/solr/handler/dataimport/TestMailEntityProcessor.java@@ -46,7 +46,6 @@ import java.util.Map;* @since solr 1.4*/@Ignore("Needs a Mock Mail Server to work")-@SuppressWarnings("unchecked")public class TestMailEntityProcessor extends AbstractDataImportHandlerTestCase {// Credentialsdiff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/ClobTransformer.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/ClobTransformer.javaindex 52656fe6e89..4bbe0467349 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/ClobTransformer.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/ClobTransformer.java@@ -36,7 +36,6 @@ import java.util.Map;* @since solr 1.4*/public class ClobTransformer extends Transformer {- @SuppressWarnings("unchecked")@Overridepublic Object transformRow(Map<String, Object> aRow, Context context) {for (Map<String, String> map : context.getAllEntityFields()) {diff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/Context.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/Context.javaindex 9cdfa0a17b5..4d0cb3a683c 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/Context.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/Context.java@@ -102,7 +102,6 @@ public abstract class Context {* @see org.apache.solr.handler.dataimport.DataSource* @see #getDataSource(String)*/- @SuppressWarnings("rawtypes")public abstract DataSource getDataSource();/**@@ -113,7 +112,6 @@ public abstract class Context {* @return a new DataSource instance* @see org.apache.solr.handler.dataimport.DataSource*/- @SuppressWarnings("rawtypes")public abstract DataSource getDataSource(String name);/**diff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/ContextImpl.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/ContextImpl.javaindex 98028cdd156..20a2aad456d 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/ContextImpl.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/ContextImpl.java@@ -31,7 +31,6 @@ import java.util.Map;** @since solr 1.3*/-@SuppressWarnings("rawtypes")public class ContextImpl extends Context {protected EntityProcessorWrapper epw;@@ -85,7 +84,7 @@ public class ContextImpl extends Context {@Overridepublic List<Map<String, String>> getAllEntityFields() {- return epw==null || epw.getEntity() == null ? Collections.emptyList() : epw.getEntity().getAllFieldsList();+ return epw==null || epw.getEntity() == null ? Collections.EMPTY_LIST : epw.getEntity().getAllFieldsList();}@Overridediff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DataImportHandler.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DataImportHandler.javaindex f01b7bbb72e..c48c332616f 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DataImportHandler.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DataImportHandler.java@@ -65,7 +65,6 @@ import static org.apache.solr.handler.dataimport.DataImporter.IMPORT_CMD;** @since solr 1.3*/-@SuppressWarnings({"rawtypes", "unchecked"})public class DataImportHandler extends RequestHandlerBase implementsSolrCoreAware {@@ -90,6 +89,7 @@ public class DataImportHandler extends RequestHandlerBase implements}@Override+ @SuppressWarnings("unchecked")public void init(NamedList args) {super.init(args);Map<String,String> macro = new HashMap<>();@@ -98,6 +98,7 @@ public class DataImportHandler extends RequestHandlerBase implements}@Override+ @SuppressWarnings("unchecked")public void inform(SolrCore core) {try {String name = getPluginInfo().name;@@ -115,6 +116,7 @@ public class DataImportHandler extends RequestHandlerBase implements}@Override+ @SuppressWarnings("unchecked")public void handleRequestBody(SolrQueryRequest req, SolrQueryResponse rsp)throws Exception {rsp.setHttpCaching(false);@@ -248,6 +250,7 @@ public class DataImportHandler extends RequestHandlerBase implements&& !writerClassStr.equals(DocBuilder.class.getPackage().getName() + "."+ DEFAULT_WRITER_NAME)) {try {+ @SuppressWarnings("unchecked")Class<DIHWriter> writerClass = DocBuilder.loadClass(writerClassStr, req.getCore());Constructor<DIHWriter> cnstr = writerClass.getConstructor(new Class[] {UpdateRequestProcessor.class, SolrQueryRequest.class});diff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DataImporter.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DataImporter.javaindex 89ad15be72a..932849bbd9b 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DataImporter.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DataImporter.java@@ -68,7 +68,6 @@ import java.util.concurrent.locks.ReentrantLock;** @since solr 1.3*/-@SuppressWarnings({"rawtypes", "unchecked"})public class DataImporter {public enum Status {@@ -188,7 +187,6 @@ public class DataImporter {config = loadDataConfig(configFile);}- @SuppressWarnings("deprecation")public DIHConfiguration loadDataConfig(InputSource configFile) {DIHConfiguration dihcfg = null;@@ -329,6 +327,7 @@ public class DataImporter {return new DIHConfiguration(documentTags.get(0), this, functions, script, dataSources, pw);}+ @SuppressWarnings("unchecked")private DIHProperties createPropertyWriter() {DIHProperties propWriter = null;PropertyWriter configPw = config.getPropertyWriter();@@ -490,6 +489,7 @@ public class DataImporter {}}+ @SuppressWarnings("unchecked")Map<String, String> getStatusMessages() {//this map object is a Collections.synchronizedMap(new LinkedHashMap()). if we// synchronize on the object it must be safe to iterate through the mapdiff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DateFormatTransformer.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DateFormatTransformer.javaindex f514e21a97e..6da9cc1b08b 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DateFormatTransformer.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DateFormatTransformer.java@@ -42,6 +42,7 @@ public class DateFormatTransformer extends Transformer {private static final Logger log = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());@Override+ @SuppressWarnings("unchecked")public Object transformRow(Map<String, Object> aRow, Context context) {for (Map<String, String> map : context.getAllEntityFields()) {@@ -67,7 +68,6 @@ public class DateFormatTransformer extends Transformer {try {Object o = aRow.get(srcCol);if (o instanceof List) {- @SuppressWarnings("rawtypes")List inputs = (List) o;List<Date> results = new ArrayList<>();for (Object input : inputs) {diff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DebugLogger.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DebugLogger.javaindex e4751bea680..2fd93031073 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DebugLogger.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DebugLogger.java@@ -41,7 +41,6 @@ import java.util.Stack;** @since solr 1.3*/-@SuppressWarnings({"rawtypes", "unchecked"})class DebugLogger {private Stack<DebugInfo> debugStack;@@ -55,7 +54,6 @@ class DebugLogger {boolean enabled = true;- @SuppressWarnings("serial")public DebugLogger() {// writer = solrWriter;output = new NamedList();diff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DocBuilder.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DocBuilder.javaindex f4181f00580..285b135c9a0 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DocBuilder.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/DocBuilder.java@@ -48,7 +48,6 @@ import java.util.concurrent.atomic.AtomicLong;** @since solr 1.3*/-@SuppressWarnings({"rawtypes", "unchecked"})public class DocBuilder {private static final Logger log = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());diff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/EntityProcessorWrapper.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/EntityProcessorWrapper.javaindex 517b00dcbbe..984f0303e33 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/EntityProcessorWrapper.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/EntityProcessorWrapper.java@@ -40,7 +40,6 @@ import java.util.Map;** @since solr 1.4*/-@SuppressWarnings({"rawtypes", "unchecked"})public class EntityProcessorWrapper extends EntityProcessor {private static final Logger log = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());@@ -79,7 +78,7 @@ public class EntityProcessorWrapper extends EntityProcessor {}- @SuppressWarnings("serial")+ @SuppressWarnings("unchecked")void loadTransformers() {String transClasses = context.getEntityAttribute(TRANSFORMER);@@ -150,6 +149,7 @@ public class EntityProcessorWrapper extends EntityProcessor {}}+ @SuppressWarnings("unchecked")static class ReflectionTransformer extends Transformer {final Method meth;@@ -185,6 +185,7 @@ public class EntityProcessorWrapper extends EntityProcessor {return r;}+ @SuppressWarnings("unchecked")protected Map<String, Object> applyTransformer(Map<String, Object> row) {if(row == null) return null;if (transformers == null)diff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/HTMLStripTransformer.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/HTMLStripTransformer.javaindex 62754b761e0..e62c329283e 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/HTMLStripTransformer.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/HTMLStripTransformer.java@@ -35,7 +35,7 @@ import java.util.Map;public class HTMLStripTransformer extends Transformer {@Override- @SuppressWarnings({"unchecked", "rawtypes"})+ @SuppressWarnings("unchecked")public Object transformRow(Map<String, Object> row, Context context) {List<Map<String, String>> fields = context.getAllEntityFields();for (Map<String, String> field : fields) {diff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/JdbcDataSource.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/JdbcDataSource.javaindex a8cacce22d2..5eb35172466 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/JdbcDataSource.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/JdbcDataSource.java@@ -170,7 +170,6 @@ public class JdbcDataSource extends}return factory = new Callable<Connection>() {- @SuppressWarnings("unchecked")@Overridepublic Connection call() throws Exception {log.info("Creating a connection for entity "diff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/LineEntityProcessor.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/LineEntityProcessor.javaindex 1a871606fea..0940cbd4cf4 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/LineEntityProcessor.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/LineEntityProcessor.java@@ -129,7 +129,6 @@ public class LineEntityProcessor extends EntityProcessorBase {}}- @SuppressWarnings("deprecation")public void closeResources() {if (reader != null) {IOUtils.closeQuietly(reader);diff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/NumberFormatTransformer.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/NumberFormatTransformer.javaindex 665ba6d2339..349b14eee30 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/NumberFormatTransformer.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/NumberFormatTransformer.java@@ -44,7 +44,7 @@ import java.util.Map;public class NumberFormatTransformer extends Transformer {@Override- @SuppressWarnings({"unchecked", "rawtypes"})+ @SuppressWarnings("unchecked")public Object transformRow(Map<String, Object> row, Context context) {for (Map<String, String> fld : context.getAllEntityFields()) {String style = context.replaceTokens(fld.get(FORMAT_STYLE));diff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/PlainTextEntityProcessor.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/PlainTextEntityProcessor.javaindex e378488ac72..c75608c95a9 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/PlainTextEntityProcessor.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/PlainTextEntityProcessor.java@@ -42,7 +42,6 @@ public class PlainTextEntityProcessor extends EntityProcessorBase {ended = false;}- @SuppressWarnings({"unchecked", "deprecation"})@Overridepublic Map<String, Object> nextRow() {if (ended) return null;diff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/RegexTransformer.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/RegexTransformer.javaindex 9825d64d214..719decae906 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/RegexTransformer.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/RegexTransformer.java@@ -43,7 +43,7 @@ public class RegexTransformer extends Transformer {private static final Logger log = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());@Override- @SuppressWarnings({"unchecked", "rawtypes"})+ @SuppressWarnings("unchecked")public Map<String, Object> transformRow(Map<String, Object> row,Context ctx) {List<Map<String, String>> fields = ctx.getAllEntityFields();@@ -128,13 +128,14 @@ public class RegexTransformer extends Transformer {}}+ @SuppressWarnings("unchecked")private List<String> readBySplit(String splitBy, String value) {String[] vals = value.split(splitBy);List<String> l = new ArrayList<>(Arrays.asList(vals));return l;}- @SuppressWarnings({"unchecked", "rawtypes"})+ @SuppressWarnings("unchecked")private Object readfromRegExp(String reStr, String value, String columnName, String gNames) {String[] groupNames = null;if(gNames != null && gNames.trim().length() >0){diff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/TemplateTransformer.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/TemplateTransformer.javaindex 299550930ba..f655edd17d8 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/TemplateTransformer.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/TemplateTransformer.java@@ -52,6 +52,7 @@ public class TemplateTransformer extends Transformer {private Map<String ,List<String>> templateVsVars = new HashMap<>();@Override+ @SuppressWarnings("unchecked")public Object transformRow(Map<String, Object> row, Context context) {@@ -93,7 +94,6 @@ public class TemplateTransformer extends Transformer {return row;}- @SuppressWarnings({"unchecked", "rawtypes"})private void addToRow(String key, Map<String, Object> row, Object value) {Object prevVal = row.get(key);if (prevVal != null) {diff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/XPathEntityProcessor.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/XPathEntityProcessor.javaindex addee547e17..c93b581fdfc 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/XPathEntityProcessor.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/XPathEntityProcessor.java@@ -100,7 +100,6 @@ public class XPathEntityProcessor extends EntityProcessorBase {}- @SuppressWarnings("deprecation")private void initXpathReader(VariableResolver resolver) {reinitXPathReader = false;useSolrAddXml = Boolean.parseBoolean(context@@ -184,7 +183,7 @@ public class XPathEntityProcessor extends EntityProcessorBase {}}String url = context.getEntityAttribute(URL);- List<String> l = url == null ? Collections.emptyList() : resolver.getVariables(url);+ List<String> l = url == null ? Collections.EMPTY_LIST : resolver.getVariables(url);for (String s : l) {if (s.startsWith(entityName + ".")) {if (placeHolderVariables == null)@@ -225,6 +224,7 @@ public class XPathEntityProcessor extends EntityProcessorBase {readUsefulVars(r);}+ @SuppressWarnings("unchecked")private Map<String, Object> fetchNextRow() {Map<String, Object> r = null;while (true) {@@ -283,7 +283,6 @@ public class XPathEntityProcessor extends EntityProcessorBase {}- @SuppressWarnings("unchecked")private void initQuery(String s) {Reader data = null;try {@@ -356,7 +355,6 @@ public class XPathEntityProcessor extends EntityProcessorBase {}}- @SuppressWarnings({"unchecked", "rawtypes"})protected Map<String, Object> readRow(Map<String, Object> record, String xpath) {if (useSolrAddXml) {List<String> names = (List<String>) record.get("name");@@ -393,6 +391,7 @@ public class XPathEntityProcessor extends EntityProcessorBase {}+ @SuppressWarnings("unchecked")private Map<String, Object> readUsefulVars(Map<String, Object> r) {Object val = r.get(HAS_MORE);if (val != null)diff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/XPathRecordReader.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/XPathRecordReader.javaindex db0fbeb76c0..13daf49b085 100644--- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/XPathRecordReader.java+++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/XPathRecordReader.java@@ -585,7 +585,6 @@ public class XPathRecordReader {* records values. If a fields value is a List then they have to be* deep-copied for thread safety*/- @SuppressWarnings("unchecked")private static Map<String, Object> getDeepCopy(Map<String, Object> values) {Map<String, Object> result = new HashMap<>();for (Map.Entry<String, Object> entry : values.entrySet()) {diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/AbstractDIHCacheTestCase.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/AbstractDIHCacheTestCase.javaindex 7a7b3ec88ca..9a0f3a772e7 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/AbstractDIHCacheTestCase.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/AbstractDIHCacheTestCase.java@@ -81,7 +81,7 @@ public class AbstractDIHCacheTestCase {}@Override- @SuppressWarnings({"unchecked", "rawtypes"})+ @SuppressWarnings("unchecked")public int compareTo(ControlData cd) {Comparable c1 = (Comparable) data[0];Comparable c2 = (Comparable) cd.data[0];diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/AbstractDIHJdbcTestCase.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/AbstractDIHJdbcTestCase.javaindex c8c94bfc03d..5428e186a42 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/AbstractDIHJdbcTestCase.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/AbstractDIHJdbcTestCase.java@@ -24,7 +24,7 @@ import java.sql.Statement;import java.util.regex.Matcher;import java.util.regex.Pattern;-import org.junit.Assert;+import junit.framework.Assert;import org.apache.solr.request.LocalSolrQueryRequest;import org.junit.After;diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/AbstractDataImportHandlerTestCase.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/AbstractDataImportHandlerTestCase.javaindex 2c4c4381a09..3674a3d58f1 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/AbstractDataImportHandlerTestCase.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/AbstractDataImportHandlerTestCase.java@@ -115,7 +115,6 @@ public abstract class AbstractDataImportHandlerTestCase extends* @param extraParams any extra request parameters needed to be passed to DataImportHandler* @throws Exception in case of any error*/- @SuppressWarnings({"rawtypes", "unchecked"})protected void runFullImport(String dataConfig, Map<String, String> extraParams) throws Exception {HashMap<String, String> params = new HashMap<>();params.put("command", "full-import");@@ -135,7 +134,7 @@ public abstract class AbstractDataImportHandlerTestCase extends/*** Helper for creating a Context instance. Useful for testing Transformers*/- @SuppressWarnings("rawtypes")+ @SuppressWarnings("unchecked")public static TestContext getContext(EntityProcessorWrapper parent,VariableResolver resolver, DataSource parentDataSource,String currProcess, final List<Map<String, String>> entityFields,@@ -151,7 +150,7 @@ public abstract class AbstractDataImportHandlerTestCase extends* Strings at even index are keys, odd-index strings are values in the* returned map*/- @SuppressWarnings("rawtypes")+ @SuppressWarnings("unchecked")public static Map createMap(Object... args) {return Utils.makeMap(args);}@@ -217,7 +216,6 @@ public abstract class AbstractDataImportHandlerTestCase extendsreturn delegate.getVariableResolver();}- @SuppressWarnings("rawtypes")@Overridepublic DataSource getDataSource() {return delegate.getDataSource();@@ -258,7 +256,6 @@ public abstract class AbstractDataImportHandlerTestCase extendsreturn delegate.getParentContext();}- @SuppressWarnings("rawtypes")@Overridepublic DataSource getDataSource(String name) {return delegate.getDataSource(name);diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/AbstractSqlEntityProcessorTestCase.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/AbstractSqlEntityProcessorTestCase.javaindex dc06fc28a48..277404451c1 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/AbstractSqlEntityProcessorTestCase.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/AbstractSqlEntityProcessorTestCase.java@@ -16,7 +16,7 @@*/package org.apache.solr.handler.dataimport;-import org.junit.Assert;+import junit.framework.Assert;import org.apache.solr.common.util.SuppressForbidden;import org.junit.After;import org.junit.Before;diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/MockInitialContextFactory.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/MockInitialContextFactory.javaindex b32660aae73..756821027ed 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/MockInitialContextFactory.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/MockInitialContextFactory.java@@ -41,6 +41,7 @@ public class MockInitialContextFactory implements InitialContextFactory {}@Override+ @SuppressWarnings("unchecked")public javax.naming.Context getInitialContext(Hashtable env) {return context;}diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestClobTransformer.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestClobTransformer.javaindex 215234b07cb..fe00d491d04 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestClobTransformer.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestClobTransformer.java@@ -42,7 +42,7 @@ public class TestClobTransformer extends AbstractDataImportHandlerTestCase {f.put(ClobTransformer.CLOB, "true");f.put(DataImporter.NAME, "description");flds.add(f);- Context ctx = getContext(null, new VariableResolver(), null, Context.FULL_DUMP, flds, Collections.emptyMap());+ Context ctx = getContext(null, new VariableResolver(), null, Context.FULL_DUMP, flds, Collections.EMPTY_MAP);Transformer t = new ClobTransformer();Map<String, Object> row = new HashMap<>();Clob clob = (Clob) Proxy.newProxyInstance(this.getClass().getClassLoader(), new Class[]{Clob.class}, new InvocationHandler() {diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestContentStreamDataSource.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestContentStreamDataSource.javaindex b006665e991..34e50e00c7e 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestContentStreamDataSource.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestContentStreamDataSource.java@@ -65,7 +65,6 @@ public class TestContentStreamDataSource extends AbstractDataImportHandlerTestCasuper.tearDown();}- @SuppressWarnings("rawtypes")@Testpublic void testSimple() throws Exception {DirectXmlRequest req = new DirectXmlRequest("/dataimport", xml);diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestDataConfig.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestDataConfig.javaindex 1ea4a5ee160..7a56fd2f36e 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestDataConfig.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestDataConfig.java@@ -42,7 +42,7 @@ public class TestDataConfig extends AbstractDataImportHandlerTestCase {}@Test- @SuppressWarnings({"unchecked", "rawtypes"})+ @SuppressWarnings("unchecked")public void testDataConfigWithDataSource() throws Exception {List rows = new ArrayList();rows.add(createMap("id", "1", "desc", "one"));diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestDocBuilder.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestDocBuilder.javaindex 0cbee682b9f..7f7278e7d0b 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestDocBuilder.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestDocBuilder.java@@ -51,7 +51,6 @@ public class TestDocBuilder extends AbstractDataImportHandlerTestCase {assertNotNull(clz);}- @SuppressWarnings("unchecked")@Testpublic void singleEntityNoRows() {DataImporter di = new DataImporter();@@ -71,7 +70,6 @@ public class TestDocBuilder extends AbstractDataImportHandlerTestCase {assertEquals(0, di.getDocBuilder().importStatistics.rowsCount.get());}- @SuppressWarnings("unchecked")@Testpublic void testDeltaImportNoRows_MustNotCommit() {DataImporter di = new DataImporter();@@ -94,7 +92,6 @@ public class TestDocBuilder extends AbstractDataImportHandlerTestCase {assertEquals(0, di.getDocBuilder().importStatistics.rowsCount.get());}- @SuppressWarnings("unchecked")@Testpublic void singleEntityOneRow() {DataImporter di = new DataImporter();@@ -124,7 +121,6 @@ public class TestDocBuilder extends AbstractDataImportHandlerTestCase {}}- @SuppressWarnings("unchecked")@Testpublic void testImportCommand() {DataImporter di = new DataImporter();@@ -154,7 +150,6 @@ public class TestDocBuilder extends AbstractDataImportHandlerTestCase {}}- @SuppressWarnings("unchecked")@Testpublic void singleEntityMultipleRows() {DataImporter di = new DataImporter();@@ -187,7 +182,6 @@ public class TestDocBuilder extends AbstractDataImportHandlerTestCase {assertEquals(3, di.getDocBuilder().importStatistics.rowsCount.get());}- @SuppressWarnings("unchecked")@Testpublic void templateXPath() {DataImporter di = new DataImporter();diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestDocBuilder2.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestDocBuilder2.javaindex 6279a23b73c..27865cd5e34 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestDocBuilder2.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestDocBuilder2.java@@ -36,7 +36,6 @@ import java.nio.charset.StandardCharsets;** @since solr 1.3*/-@SuppressWarnings({"unchecked", "rawtypes"})public class TestDocBuilder2 extends AbstractDataImportHandlerTestCase {@BeforeClass@@ -45,6 +44,7 @@ public class TestDocBuilder2 extends AbstractDataImportHandlerTestCase {}@Test+ @SuppressWarnings("unchecked")public void testSingleEntity() throws Exception {List rows = new ArrayList();rows.add(createMap("id", "1", "desc", "one"));@@ -60,6 +60,7 @@ public class TestDocBuilder2 extends AbstractDataImportHandlerTestCase {}@Test+ @SuppressWarnings("unchecked")public void testSingleEntity_CaseInsensitive() throws Exception {List rows = new ArrayList();rows.add(createMap("id", "1", "desC", "one"));@@ -87,6 +88,7 @@ public class TestDocBuilder2 extends AbstractDataImportHandlerTestCase {}@Test+ @SuppressWarnings("unchecked")public void testDynamicFields() throws Exception {List rows = new ArrayList();rows.add(createMap("id", "1", "desc", "one"));@@ -99,6 +101,7 @@ public class TestDocBuilder2 extends AbstractDataImportHandlerTestCase {}@Test+ @SuppressWarnings("unchecked")public void testRequestParamsAsVariable() throws Exception {List rows = new ArrayList();rows.add(createMap("id", "101", "desc", "ApacheSolr"));@@ -113,6 +116,7 @@ public class TestDocBuilder2 extends AbstractDataImportHandlerTestCase {}@Test+ @SuppressWarnings("unchecked")public void testDynamicFieldNames() throws Exception {List rows = new ArrayList();rows.add(createMap("mypk", "101", "text", "ApacheSolr"));@@ -126,6 +130,7 @@ public class TestDocBuilder2 extends AbstractDataImportHandlerTestCase {}@Test+ @SuppressWarnings("unchecked")public void testRequestParamsAsFieldName() throws Exception {List rows = new ArrayList();rows.add(createMap("mypk", "101", "text", "ApacheSolr"));@@ -140,6 +145,7 @@ public class TestDocBuilder2 extends AbstractDataImportHandlerTestCase {}@Test+ @SuppressWarnings("unchecked")public void testContext() throws Exception {List rows = new ArrayList();rows.add(createMap("id", "1", "desc", "one"));@@ -149,6 +155,7 @@ public class TestDocBuilder2 extends AbstractDataImportHandlerTestCase {}@Test+ @SuppressWarnings("unchecked")public void testSkipDoc() throws Exception {List rows = new ArrayList();rows.add(createMap("id", "1", "desc", "one"));@@ -162,6 +169,7 @@ public class TestDocBuilder2 extends AbstractDataImportHandlerTestCase {}@Test+ @SuppressWarnings("unchecked")public void testSkipRow() throws Exception {List rows = new ArrayList();rows.add(createMap("id", "1", "desc", "one"));@@ -196,6 +204,7 @@ public class TestDocBuilder2 extends AbstractDataImportHandlerTestCase {}@Test+ @SuppressWarnings("unchecked")public void testStopTransform() throws Exception {List rows = new ArrayList();rows.add(createMap("id", "1", "desc", "one"));@@ -210,6 +219,7 @@ public class TestDocBuilder2 extends AbstractDataImportHandlerTestCase {}@Test+ @SuppressWarnings("unchecked")public void testDeleteDocs() throws Exception {List rows = new ArrayList();rows.add(createMap("id", "1", "desc", "one"));diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestEphemeralCache.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestEphemeralCache.javaindex 351ec4654d2..ddccafeaa3e 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestEphemeralCache.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestEphemeralCache.java@@ -44,7 +44,7 @@ public class TestEphemeralCache extends AbstractDataImportHandlerTestCase {assertFullImport(getDataConfigDotXml());}- @SuppressWarnings({"unchecked", "rawtypes"})+ @SuppressWarnings("unchecked")private void setupMockData() {List parentRows = new ArrayList();parentRows.add(createMap("id", new BigDecimal("1"), "parent_s", "one"));diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestErrorHandling.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestErrorHandling.javaindex 441125121ef..1ea1ad483a1 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestErrorHandling.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestErrorHandling.java@@ -80,7 +80,6 @@ public class TestErrorHandling extends AbstractDataImportHandlerTestCase {assertQ(req("*:*"), "//*[@numFound='0']");}- @SuppressWarnings("unchecked")public void testTransformerErrorContinue() throws Exception {StringDataSource.xml = wellformedXml;List<Map<String, Object>> rows = new ArrayList<>();diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestFieldReader.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestFieldReader.javaindex fc57c14f975..347a40bf1ab 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestFieldReader.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestFieldReader.java@@ -31,7 +31,6 @@ import java.util.Map;*/public class TestFieldReader extends AbstractDataImportHandlerTestCase {- @SuppressWarnings("unchecked")@Testpublic void simple() {DataImporter di = new DataImporter();diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestFileListEntityProcessor.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestFileListEntityProcessor.javaindex 6cbac9ae73c..dd2cf72f642 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestFileListEntityProcessor.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestFileListEntityProcessor.java@@ -40,10 +40,10 @@ import org.junit.Test;** @since solr 1.3*/-@SuppressWarnings({"unchecked", "rawtypes"})public class TestFileListEntityProcessor extends AbstractDataImportHandlerTestCase {@Test+ @SuppressWarnings("unchecked")public void testSimple() throws IOException {File tmpdir = createTempDir().toFile();@@ -119,6 +119,7 @@ public class TestFileListEntityProcessor extends AbstractDataImportHandlerTestCaassertEquals(l, new HashSet<>(fList));}+ @SuppressWarnings("unchecked")static List<String> getFiles(VariableResolver resolver, Map attrs) {Context c = getContext(null,resolver, null, Context.FULL_DUMP, Collections.EMPTY_LIST, attrs);diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestJdbcDataSourceConvertType.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestJdbcDataSourceConvertType.javaindex 80436a84e2d..94f437c3709 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestJdbcDataSourceConvertType.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestJdbcDataSourceConvertType.java@@ -30,7 +30,6 @@ import java.util.Map;import java.util.Objects;import java.util.Properties;-@SuppressWarnings("deprecation")@ThreadLeakAction({ThreadLeakAction.Action.WARN})@ThreadLeakLingering(linger = 0)@ThreadLeakZombies(ThreadLeakZombies.Consequence.CONTINUE)@@ -49,7 +48,6 @@ public class TestJdbcDataSourceConvertType extends AbstractDataImportHandlerTestconvertTypeTest("true", Long.class);}- @SuppressWarnings("rawtypes")private void convertTypeTest(String convertType, Class resultClass) throws Throwable {JdbcDataSource dataSource = new JdbcDataSource();Properties p = new Properties();diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestLineEntityProcessor.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestLineEntityProcessor.javaindex f8a65087880..eb9989c181a 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestLineEntityProcessor.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestLineEntityProcessor.java@@ -31,7 +31,6 @@ import java.util.*;*/public class TestLineEntityProcessor extends AbstractDataImportHandlerTestCase {- @SuppressWarnings({"rawtypes", "unchecked"})@Test/************************************************************************/public void testSimple() throws IOException {@@ -54,7 +53,7 @@ public class TestLineEntityProcessor extends AbstractDataImportHandlerTestCase {new VariableResolver(), //resolvergetDataSource(filecontents), //parentDataSourceContext.FULL_DUMP, //currProcess- Collections.emptyList(), //entityFields+ Collections.EMPTY_LIST, //entityFieldsattrs //entityAttrs);LineEntityProcessor ep = new LineEntityProcessor();@@ -72,7 +71,6 @@ public class TestLineEntityProcessor extends AbstractDataImportHandlerTestCase {assertEquals(24, fList.size());}- @SuppressWarnings("rawtypes")@Test/************************************************************************/public void testOnly_xml_files() throws IOException {@@ -90,13 +88,12 @@ public class TestLineEntityProcessor extends AbstractDataImportHandlerTestCase {LineEntityProcessor.SKIP_LINE_REGEX, null);- @SuppressWarnings("unchecked")Context c = getContext(null, //parentEntitynew VariableResolver(), //resolvergetDataSource(filecontents), //parentDataSourceContext.FULL_DUMP, //currProcess- Collections.emptyList(), //entityFields+ Collections.EMPTY_LIST, //entityFieldsattrs //entityAttrs);LineEntityProcessor ep = new LineEntityProcessor();@@ -112,7 +109,6 @@ public class TestLineEntityProcessor extends AbstractDataImportHandlerTestCase {assertEquals(5, fList.size());}- @SuppressWarnings("rawtypes")@Test/************************************************************************/public void testOnly_xml_files_no_xsd() throws IOException {@@ -130,13 +126,12 @@ public class TestLineEntityProcessor extends AbstractDataImportHandlerTestCase {LineEntityProcessor.SKIP_LINE_REGEX, "\\.xsd");- @SuppressWarnings("unchecked")Context c = getContext(null, //parentEntitynew VariableResolver(), //resolvergetDataSource(filecontents), //parentDataSourceContext.FULL_DUMP, //currProcess- Collections.emptyList(), //entityFields+ Collections.EMPTY_LIST, //entityFieldsattrs //entityAttrs);LineEntityProcessor ep = new LineEntityProcessor();@@ -152,7 +147,6 @@ public class TestLineEntityProcessor extends AbstractDataImportHandlerTestCase {assertEquals(4, fList.size());}- @SuppressWarnings("rawtypes")@Test/************************************************************************/public void testNo_xsd_files() throws IOException {@@ -168,13 +162,12 @@ public class TestLineEntityProcessor extends AbstractDataImportHandlerTestCase {LineEntityProcessor.SKIP_LINE_REGEX, "\\.xsd");- @SuppressWarnings("unchecked")Context c = getContext(null, //parentEntitynew VariableResolver(), //resolvergetDataSource(filecontents), //parentDataSourceContext.FULL_DUMP, //currProcess- Collections.emptyList(), //entityFields+ Collections.EMPTY_LIST, //entityFieldsattrs //entityAttrs);LineEntityProcessor ep = new LineEntityProcessor();diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestPlainTextEntityProcessor.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestPlainTextEntityProcessor.javaindex be9eb4b902f..23854382dde 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestPlainTextEntityProcessor.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestPlainTextEntityProcessor.java@@ -39,7 +39,6 @@ import static java.nio.charset.StandardCharsets.UTF_8;* @since solr 1.4*/public class TestPlainTextEntityProcessor extends AbstractDataImportHandlerTestCase {- @SuppressWarnings("unchecked")@Testpublic void testSimple() throws IOException {DataImporter di = new DataImporter();@@ -115,7 +114,6 @@ public class TestPlainTextEntityProcessor extends AbstractDataImportHandlerTestC}}- @SuppressWarnings("unchecked")@Testpublic void testSimple2() throws IOException {DataImporter di = new DataImporter();@@ -150,7 +148,6 @@ public class TestPlainTextEntityProcessor extends AbstractDataImportHandlerTestC}- @SuppressWarnings("rawtypes")public static class DS extends DataSource {static String s = "hello world";diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestRegexTransformer.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestRegexTransformer.javaindex 0d4971ddd6a..e792804634f 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestRegexTransformer.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestRegexTransformer.java@@ -36,7 +36,6 @@ import java.util.Map;*/public class TestRegexTransformer extends AbstractDataImportHandlerTestCase {- @SuppressWarnings("rawtypes")@Testpublic void testCommaSeparated() {List<Map<String, String>> fields = new ArrayList<>();@@ -53,7 +52,6 @@ public class TestRegexTransformer extends AbstractDataImportHandlerTestCase {}- @SuppressWarnings({"unchecked", "rawtypes"})@Testpublic void testGroupNames() {List<Map<String, String>> fields = new ArrayList<>();@@ -116,7 +114,6 @@ public class TestRegexTransformer extends AbstractDataImportHandlerTestCase {assertEquals("valueWithoutSpaces", result.get("title_underscore")); // value should be returned as-is}- @SuppressWarnings("unchecked")@Testpublic void testMileage() {// init a whole pile of fields@@ -166,7 +163,6 @@ public class TestRegexTransformer extends AbstractDataImportHandlerTestCase {assertEquals("Fuel Economy range: 26 mpg Hwy, 19 mpg City", result.get("t3"));}- @SuppressWarnings("unchecked")@Testpublic void testMultiValuedRegex(){List<Map<String, String>> fields = new ArrayList<>();diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestScriptTransformer.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestScriptTransformer.javaindex 3262bfd59c8..c106f8e5a5d 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestScriptTransformer.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestScriptTransformer.java@@ -35,7 +35,6 @@ import java.util.Map;** @since solr 1.3*/-@SuppressWarnings({"rawtypes", "unchecked"})public class TestScriptTransformer extends AbstractDataImportHandlerTestCase {@Testdiff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestSolrEntityProcessorUnit.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestSolrEntityProcessorUnit.javaindex 19162108023..a2a9fffa9ab 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestSolrEntityProcessorUnit.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestSolrEntityProcessorUnit.java@@ -27,7 +27,6 @@ import org.junit.Test;/*** Unit test of SolrEntityProcessor. A very basic test outside of the DIH.*/-@SuppressWarnings("rawtypes")public class TestSolrEntityProcessorUnit extends AbstractDataImportHandlerTestCase {private static final class NoNextMockProcessor extends SolrEntityProcessor {@@ -67,7 +66,6 @@ public class TestSolrEntityProcessorUnit extends AbstractDataImportHandlerTestCa}}- @SuppressWarnings("serial")private MockSolrEntityProcessor createAndInit(List<Doc> docs, int rowsNum) {MockSolrEntityProcessor processor = new MockSolrEntityProcessor(docs, rowsNum);HashMap<String,String> entityAttrs = new HashMap<String,String>(){{put(SolrEntityProcessor.SOLR_SERVER,"http://route:66/no");}};@@ -99,7 +97,6 @@ public class TestSolrEntityProcessorUnit extends AbstractDataImportHandlerTestCaprocessor.destroy();}}- @SuppressWarnings("serial")@Test (expected = DataImportHandlerException.class)public void testNoQuery() {SolrEntityProcessor processor = new SolrEntityProcessor();@@ -114,7 +111,6 @@ public class TestSolrEntityProcessorUnit extends AbstractDataImportHandlerTestCa}}- @SuppressWarnings("serial")public void testPagingQuery() {SolrEntityProcessor processor = new NoNextMockProcessor() ;@@ -139,7 +135,6 @@ public class TestSolrEntityProcessorUnit extends AbstractDataImportHandlerTestCa}}- @SuppressWarnings("serial")public void testCursorQuery() {SolrEntityProcessor processor = new NoNextMockProcessor() ;diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestSortedMapBackedCache.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestSortedMapBackedCache.javaindex 8d6a5c602a5..7b0e613ea75 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestSortedMapBackedCache.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestSortedMapBackedCache.java@@ -105,7 +105,6 @@ public class TestSortedMapBackedCache extends AbstractDIHCacheTestCase {}}- @SuppressWarnings("unused")@Testpublic void testCacheReopensWithUpdate() {DIHCache cache = null;diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestTemplateTransformer.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestTemplateTransformer.javaindex b1898954c3c..b5c38117ac3 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestTemplateTransformer.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestTemplateTransformer.java@@ -31,10 +31,10 @@ import java.util.Arrays;** @since solr 1.3*/-@SuppressWarnings({"unchecked", "rawtypes"})public class TestTemplateTransformer extends AbstractDataImportHandlerTestCase {@Test+ @SuppressWarnings("unchecked")public void testTransformRow() {List fields = new ArrayList();fields.add(createMap("column", "firstName"));@@ -71,6 +71,7 @@ public class TestTemplateTransformer extends AbstractDataImportHandlerTestCase {}@Test+ @SuppressWarnings("unchecked")public void testTransformRowMultiValue() {List fields = new ArrayList();fields.add(createMap("column", "year"));diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestVariableResolver.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestVariableResolver.javaindex 1431de209a6..00285649fe6 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestVariableResolver.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestVariableResolver.java@@ -147,7 +147,7 @@ public class TestVariableResolver extends AbstractDataImportHandlerTestCase {l.add(m);resolver.setEvaluators(new DataImporter().getEvaluators(l));ContextImpl context = new ContextImpl(null, resolver, null,- Context.FULL_DUMP, Collections.emptyMap(), null, null);+ Context.FULL_DUMP, Collections.EMPTY_MAP, null, null);SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss'Z'", Locale.ROOT);format.setTimeZone(TimeZone.getTimeZone("UTC"));diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestVariableResolverEndToEnd.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestVariableResolverEndToEnd.javaindex 78477103fb8..8ee6878c0ee 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestVariableResolverEndToEnd.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestVariableResolverEndToEnd.java@@ -23,7 +23,7 @@ import java.util.Locale;import java.util.regex.Matcher;import java.util.regex.Pattern;-import org.junit.Assert;+import junit.framework.Assert;import org.apache.solr.request.SolrQueryRequest;import org.junit.Test;diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestWriterImpl.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestWriterImpl.javaindex c56d658ac3f..e5c2a949f25 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestWriterImpl.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestWriterImpl.java@@ -41,7 +41,7 @@ public class TestWriterImpl extends AbstractDataImportHandlerTestCase {}@Test- @SuppressWarnings({"unchecked", "rawtypes"})+ @SuppressWarnings("unchecked")public void testDataConfigWithDataSource() throws Exception {List rows = new ArrayList();rows.add(createMap("id", "1", "desc", "one"));diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestXPathEntityProcessor.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestXPathEntityProcessor.javaindex 62f638d2bc9..72da77a60ba 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestXPathEntityProcessor.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestXPathEntityProcessor.java@@ -36,7 +36,6 @@ import org.junit.Test;** @since solr 1.3*/-@SuppressWarnings({"rawtypes", "unchecked"})public class TestXPathEntityProcessor extends AbstractDataImportHandlerTestCase {boolean simulateSlowReader;boolean simulateSlowResultProcessor;@@ -94,6 +93,7 @@ public class TestXPathEntityProcessor extends AbstractDataImportHandlerTestCaseassertEquals("ü", l.get(2));}+ @SuppressWarnings({"rawtypes", "unchecked"})@Testpublic void testMultiValuedWithMultipleDocuments() throws Exception {Map entityAttrs = createMap("name", "e", "url", "testdata.xml", XPathEntityProcessor.FOR_EACH, "/documents/doc");diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestXPathRecordReader.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestXPathRecordReader.javaindex 47409fc1d30..2b0757a4ac9 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestXPathRecordReader.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestXPathRecordReader.java@@ -29,7 +29,6 @@ import org.junit.Test;** @since solr 1.3*/-@SuppressWarnings({"rawtypes", "unchecked"})public class TestXPathRecordReader extends AbstractDataImportHandlerTestCase {@Testpublic void testBasic() {diff --git a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestZKPropertiesWriter.java b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestZKPropertiesWriter.javaindex 0476a448ad4..9279d282753 100644--- a/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestZKPropertiesWriter.java+++ b/solr/contrib/dataimporthandler/src/test/org/apache/solr/handler/dataimport/TestZKPropertiesWriter.java@@ -93,7 +93,6 @@ public class TestZKPropertiesWriter extends AbstractDataImportHandlerTestCase {zkDir = null;}- @SuppressWarnings({"unchecked", "rawtypes"})@SuppressForbidden(reason = "Needs currentTimeMillis to construct date stamps")@Testpublic void testZKPropertiesWriter() throws Exception {diff --git a/solr/contrib/extraction/src/java/org/apache/solr/handler/extraction/ExtractingDocumentLoader.java b/solr/contrib/extraction/src/java/org/apache/solr/handler/extraction/ExtractingDocumentLoader.javaindex 8cc63135e57..cd5d4af576f 100644--- a/solr/contrib/extraction/src/java/org/apache/solr/handler/extraction/ExtractingDocumentLoader.java+++ b/solr/contrib/extraction/src/java/org/apache/solr/handler/extraction/ExtractingDocumentLoader.java@@ -51,6 +51,10 @@ import org.apache.tika.sax.XHTMLContentHandler;import org.apache.tika.sax.xpath.Matcher;import org.apache.tika.sax.xpath.MatchingContentHandler;import org.apache.tika.sax.xpath.XPathParser;+import org.apache.xml.serialize.BaseMarkupSerializer;+import org.apache.xml.serialize.OutputFormat;+import org.apache.xml.serialize.TextSerializer;+import org.apache.xml.serialize.XMLSerializer;import org.slf4j.Logger;import org.slf4j.LoggerFactory;import org.xml.sax.ContentHandler;@@ -127,7 +131,6 @@ public class ExtractingDocumentLoader extends ContentStreamLoader {doAdd(handler, templateAdd);}- @SuppressWarnings({"deprecation", "unchecked", "rawtypes"})@Overridepublic void load(SolrQueryRequest req, SolrQueryResponse rsp,ContentStream stream, UpdateRequestProcessor processor) throws Exception {@@ -173,16 +176,16 @@ public class ExtractingDocumentLoader extends ContentStreamLoader {ContentHandler parsingHandler = handler;StringWriter writer = null;- org.apache.xml.serialize.BaseMarkupSerializer serializer = null;+ BaseMarkupSerializer serializer = null;if (extractOnly == true) {String extractFormat = params.get(ExtractingParams.EXTRACT_FORMAT, "xml");writer = new StringWriter();if (extractFormat.equals(TEXT_FORMAT)) {- serializer = new org.apache.xml.serialize.TextSerializer();+ serializer = new TextSerializer();serializer.setOutputCharStream(writer);- serializer.setOutputFormat(new org.apache.xml.serialize.OutputFormat("Text", "UTF-8", true));+ serializer.setOutputFormat(new OutputFormat("Text", "UTF-8", true));} else {- serializer = new org.apache.xml.serialize.XMLSerializer(writer, new org.apache.xml.serialize.OutputFormat("XML", "UTF-8", true));+ serializer = new XMLSerializer(writer, new OutputFormat("XML", "UTF-8", true));}if (xpathExpr != null) {Matcher matcher =diff --git a/solr/contrib/extraction/src/java/org/apache/solr/handler/extraction/ExtractingRequestHandler.java b/solr/contrib/extraction/src/java/org/apache/solr/handler/extraction/ExtractingRequestHandler.javaindex dfa068b5cc6..3af9b5b5aa8 100644--- a/solr/contrib/extraction/src/java/org/apache/solr/handler/extraction/ExtractingRequestHandler.java+++ b/solr/contrib/extraction/src/java/org/apache/solr/handler/extraction/ExtractingRequestHandler.java@@ -55,7 +55,7 @@ public class ExtractingRequestHandler extends ContentStreamHandlerBase implement}@Override- public void init(@SuppressWarnings("rawtypes") NamedList args) {+ public void init(NamedList args) {super.init(args);}diff --git a/solr/contrib/extraction/src/java/org/apache/solr/handler/extraction/XLSXResponseWriter.java b/solr/contrib/extraction/src/java/org/apache/solr/handler/extraction/XLSXResponseWriter.javaindex aa65ad8963a..9264a1d97e5 100644--- a/solr/contrib/extraction/src/java/org/apache/solr/handler/extraction/XLSXResponseWriter.java+++ b/solr/contrib/extraction/src/java/org/apache/solr/handler/extraction/XLSXResponseWriter.java@@ -85,7 +85,6 @@ public class XLSXResponseWriter extends RawResponseWriter {}}-@SuppressWarnings("rawtypes")class XLSXWriter extends TabularResponseWriter {static class SerialWriteWorkbook {@@ -145,6 +144,7 @@ class XLSXWriter extends TabularResponseWriter {} catch (IOException e) {StringWriter sw = new StringWriter();e.printStackTrace(new PrintWriter(sw));+ String stacktrace = sw.toString();}finally {swb.dispose();}@@ -232,7 +232,6 @@ class XLSXWriter extends TabularResponseWriter {//NOTE: a document cannot currently contain another documentList tmpList;- @SuppressWarnings({"unchecked"})@Overridepublic void writeSolrDocument(String name, SolrDocument doc, ReturnFields returnFields, int idx ) throws IOException {if (tmpList == null) {diff --git a/solr/contrib/extraction/src/test/org/apache/solr/handler/extraction/ExtractingRequestHandlerTest.java b/solr/contrib/extraction/src/test/org/apache/solr/handler/extraction/ExtractingRequestHandlerTest.javaindex 96152f0a9db..14de8422ee1 100644--- a/solr/contrib/extraction/src/test/org/apache/solr/handler/extraction/ExtractingRequestHandlerTest.java+++ b/solr/contrib/extraction/src/test/org/apache/solr/handler/extraction/ExtractingRequestHandlerTest.java@@ -461,7 +461,6 @@ public class ExtractingRequestHandlerTest extends SolrTestCaseJ4 {// Note: If you load a plain text file specifying neither MIME type nor filename, extraction will silently fail. This is because Tika's// automatic MIME type detection will fail, and it will default to using an empty-string-returning default parser- @SuppressWarnings("rawtypes")@Testpublic void testExtractOnly() throws Exception {ExtractingRequestHandler handler = (ExtractingRequestHandler) h.getCore().getRequestHandler("/update/extract");@@ -499,7 +498,6 @@ public class ExtractingRequestHandlerTest extends SolrTestCaseJ4 {}- @SuppressWarnings("rawtypes")@Testpublic void testXPath() throws Exception {ExtractingRequestHandler handler = (ExtractingRequestHandler) h.getCore().getRequestHandler("/update/extract");diff --git a/solr/contrib/langid/src/java/org/apache/solr/update/processor/OpenNLPLangDetectUpdateProcessorFactory.java b/solr/contrib/langid/src/java/org/apache/solr/update/processor/OpenNLPLangDetectUpdateProcessorFactory.javaindex dd42e3caac0..b4e0253e235 100644--- a/solr/contrib/langid/src/java/org/apache/solr/update/processor/OpenNLPLangDetectUpdateProcessorFactory.java+++ b/solr/contrib/langid/src/java/org/apache/solr/update/processor/OpenNLPLangDetectUpdateProcessorFactory.java@@ -60,7 +60,6 @@ public class OpenNLPLangDetectUpdateProcessorFactory extends UpdateRequestProcesprotected SolrParams invariants;private SolrResourceLoader solrResourceLoader;- @SuppressWarnings("rawtypes")@Overridepublic void init( NamedList args ){@@ -108,7 +107,6 @@ public class OpenNLPLangDetectUpdateProcessorFactory extends UpdateRequestProcesreturn new OpenNLPLangDetectUpdateProcessor(req, rsp, next, model);}- @SuppressWarnings("deprecation")private void loadModel() throws IOException {InputStream is = null;try{diff --git a/solr/contrib/langid/src/java/org/apache/solr/update/processor/TikaLanguageIdentifierUpdateProcessor.java b/solr/contrib/langid/src/java/org/apache/solr/update/processor/TikaLanguageIdentifierUpdateProcessor.javaindex 75d175c6472..5a43bd52e79 100644--- a/solr/contrib/langid/src/java/org/apache/solr/update/processor/TikaLanguageIdentifierUpdateProcessor.java+++ b/solr/contrib/langid/src/java/org/apache/solr/update/processor/TikaLanguageIdentifierUpdateProcessor.java@@ -23,6 +23,7 @@ import java.util.List;import org.apache.solr.request.SolrQueryRequest;import org.apache.solr.response.SolrQueryResponse;+import org.apache.tika.language.LanguageIdentifier;import org.slf4j.Logger;import org.slf4j.LoggerFactory;@@ -43,13 +44,12 @@ public class TikaLanguageIdentifierUpdateProcessor extends LanguageIdentifierUpdsuper(req, rsp, next);}- @SuppressWarnings("deprecation")@Overrideprotected List<DetectedLanguage> detectLanguage(Reader solrDocReader) {String content = SolrInputDocumentReader.asString(solrDocReader);List<DetectedLanguage> languages = new ArrayList<>();if (content.length() != 0) {- org.apache.tika.language.LanguageIdentifier identifier = new org.apache.tika.language.LanguageIdentifier(content);+ LanguageIdentifier identifier = new LanguageIdentifier(content);// FIXME: Hack - we get the distance from toString and calculate our own certainty scoreDouble distance = Double.parseDouble(tikaSimilarityPattern.matcher(identifier.toString()).replaceFirst("$1"));// This formula gives: 0.02 => 0.8, 0.1 => 0.5 which is a better sweetspot than isReasonablyCertain()diff --git a/solr/contrib/langid/src/test/org/apache/solr/update/processor/LanguageIdentifierUpdateProcessorFactoryTestCase.java b/solr/contrib/langid/src/test/org/apache/solr/update/processor/LanguageIdentifierUpdateProcessorFactoryTestCase.javaindex efb4f257ef2..a74c80fea77 100644--- a/solr/contrib/langid/src/test/org/apache/solr/update/processor/LanguageIdentifierUpdateProcessorFactoryTestCase.java+++ b/solr/contrib/langid/src/test/org/apache/solr/update/processor/LanguageIdentifierUpdateProcessorFactoryTestCase.java@@ -384,7 +384,6 @@ public abstract class LanguageIdentifierUpdateProcessorFactoryTestCase extends S/*Utility test method to process a clone of a document*/- @SuppressWarnings("rawtypes")private SolrInputDocument process(SolrInputDocument origDoc) {SolrInputDocument modifiedDoc = origDoc.deepCopy();if (random().nextBoolean()) {diff --git a/solr/contrib/ltr/src/java/org/apache/solr/ltr/LTRThreadModule.java b/solr/contrib/ltr/src/java/org/apache/solr/ltr/LTRThreadModule.javaindex 9d709956970..e1426106c9e 100644--- a/solr/contrib/ltr/src/java/org/apache/solr/ltr/LTRThreadModule.java+++ b/solr/contrib/ltr/src/java/org/apache/solr/ltr/LTRThreadModule.java@@ -57,7 +57,6 @@ import org.apache.solr.util.plugin.NamedListInitializedPlugin;* <code>totalPoolThreads</code> imposes a contention between the queries if* <code>(totalPoolThreads < numThreadsPerRequest * total parallel queries)</code>.*/-@SuppressWarnings({"rawtypes", "unchecked"})final public class LTRThreadModule extends CloseHook implements NamedListInitializedPlugin {public static LTRThreadModule getInstance(NamedList args) {diff --git a/solr/contrib/ltr/src/java/org/apache/solr/ltr/model/LinearModel.java b/solr/contrib/ltr/src/java/org/apache/solr/ltr/model/LinearModel.javaindex 0c33daf9189..908b0735cc7 100644--- a/solr/contrib/ltr/src/java/org/apache/solr/ltr/model/LinearModel.java+++ b/solr/contrib/ltr/src/java/org/apache/solr/ltr/model/LinearModel.java@@ -78,7 +78,6 @@ public class LinearModel extends LTRScoringModel {*/protected Float[] featureToWeight;- @SuppressWarnings("unchecked")public void setWeights(Object weights) {final Map<String,Double> modelWeights = (Map<String,Double>) weights;for (int ii = 0; ii < features.size(); ++ii) {diff --git a/solr/contrib/ltr/src/java/org/apache/solr/ltr/model/MultipleAdditiveTreesModel.java b/solr/contrib/ltr/src/java/org/apache/solr/ltr/model/MultipleAdditiveTreesModel.javaindex 2587eed0b2c..c3e434ba013 100644--- a/solr/contrib/ltr/src/java/org/apache/solr/ltr/model/MultipleAdditiveTreesModel.java+++ b/solr/contrib/ltr/src/java/org/apache/solr/ltr/model/MultipleAdditiveTreesModel.java@@ -88,7 +88,6 @@ import org.apache.solr.util.SolrPluginUtils;* Advances in Neural Information Processing Systems (NIPS), 2007.</a>* </ul>*/-@SuppressWarnings("unchecked")public class MultipleAdditiveTreesModel extends LTRScoringModel {/**diff --git a/solr/contrib/ltr/src/java/org/apache/solr/ltr/model/NeuralNetworkModel.java b/solr/contrib/ltr/src/java/org/apache/solr/ltr/model/NeuralNetworkModel.javaindex e46b7d4cac5..d72b29b8120 100644--- a/solr/contrib/ltr/src/java/org/apache/solr/ltr/model/NeuralNetworkModel.java+++ b/solr/contrib/ltr/src/java/org/apache/solr/ltr/model/NeuralNetworkModel.java@@ -92,7 +92,6 @@ import org.apache.solr.util.SolrPluginUtils;* Proceedings of the 22nd International Conference on Machine Learning (ICML), ACM, 2005.</a>* </ul>*/-@SuppressWarnings("unchecked")public class NeuralNetworkModel extends LTRScoringModel {/**diff --git a/solr/contrib/ltr/src/java/org/apache/solr/ltr/response/transform/LTRFeatureLoggerTransformerFactory.java b/solr/contrib/ltr/src/java/org/apache/solr/ltr/response/transform/LTRFeatureLoggerTransformerFactory.javaindex cc9246f1909..c6c4d7bff64 100644--- a/solr/contrib/ltr/src/java/org/apache/solr/ltr/response/transform/LTRFeatureLoggerTransformerFactory.java+++ b/solr/contrib/ltr/src/java/org/apache/solr/ltr/response/transform/LTRFeatureLoggerTransformerFactory.java@@ -110,7 +110,6 @@ public class LTRFeatureLoggerTransformerFactory extends TransformerFactory {this.csvFeatureSeparator = csvFeatureSeparator.charAt(0);}- @SuppressWarnings("unchecked")@Overridepublic void init(@SuppressWarnings("rawtypes") NamedList args) {super.init(args);diff --git a/solr/contrib/ltr/src/java/org/apache/solr/ltr/search/LTRQParserPlugin.java b/solr/contrib/ltr/src/java/org/apache/solr/ltr/search/LTRQParserPlugin.javaindex e9e8a53cae3..af9977538ca 100644--- a/solr/contrib/ltr/src/java/org/apache/solr/ltr/search/LTRQParserPlugin.java+++ b/solr/contrib/ltr/src/java/org/apache/solr/ltr/search/LTRQParserPlugin.java@@ -78,7 +78,6 @@ public class LTRQParserPlugin extends QParserPlugin implements ResourceLoaderAwa**/public static final String RERANK_DOCS = "reRankDocs";- @SuppressWarnings("unchecked")@Overridepublic void init(@SuppressWarnings("rawtypes") NamedList args) {super.init(args);diff --git a/solr/contrib/ltr/src/java/org/apache/solr/ltr/store/rest/ManagedModelStore.java b/solr/contrib/ltr/src/java/org/apache/solr/ltr/store/rest/ManagedModelStore.javaindex f735fc9d9d4..60cabccab55 100644--- a/solr/contrib/ltr/src/java/org/apache/solr/ltr/store/rest/ManagedModelStore.java+++ b/solr/contrib/ltr/src/java/org/apache/solr/ltr/store/rest/ManagedModelStore.java@@ -105,6 +105,7 @@ public class ManagedModelStore extends ManagedResource implements ManagedResourcprivate Object managedData;+ @SuppressWarnings("unchecked")@Overrideprotected void onManagedDataLoadedFromStorage(NamedList<?> managedInitArgs,Object managedData) throws SolrException {@@ -118,7 +119,6 @@ public class ManagedModelStore extends ManagedResource implements ManagedResourc}- @SuppressWarnings("unchecked")public void loadStoredModels() {log.info("------ managed models ~ loading ------");diff --git a/solr/contrib/ltr/src/test/org/apache/solr/ltr/feature/TestFeatureExtractionFromMultipleSegments.java b/solr/contrib/ltr/src/test/org/apache/solr/ltr/feature/TestFeatureExtractionFromMultipleSegments.javaindex 0ef1d40ef67..a15178bd007 100644--- a/solr/contrib/ltr/src/test/org/apache/solr/ltr/feature/TestFeatureExtractionFromMultipleSegments.java+++ b/solr/contrib/ltr/src/test/org/apache/solr/ltr/feature/TestFeatureExtractionFromMultipleSegments.java@@ -78,7 +78,6 @@ public class TestFeatureExtractionFromMultipleSegments extends TestRerankBase {aftertest();}- @SuppressWarnings("unchecked")@Testpublic void testFeatureExtractionFromMultipleSegments() throws Exception {diff --git a/solr/contrib/ltr/src/test/org/apache/solr/ltr/feature/TestNoMatchSolrFeature.java b/solr/contrib/ltr/src/test/org/apache/solr/ltr/feature/TestNoMatchSolrFeature.javaindex 0c78d25564e..48c1262c547 100644--- a/solr/contrib/ltr/src/test/org/apache/solr/ltr/feature/TestNoMatchSolrFeature.java+++ b/solr/contrib/ltr/src/test/org/apache/solr/ltr/feature/TestNoMatchSolrFeature.java@@ -83,7 +83,6 @@ public class TestNoMatchSolrFeature extends TestRerankBase {aftertest();}- @SuppressWarnings("unchecked")@Testpublic void test2NoMatch1YesMatchFeatureReturnsFvWith1FeatureAndDocScoreScaledByModel() throws Exception {// Tests model with all no matching features but 1@@ -150,7 +149,6 @@ public class TestNoMatchSolrFeature extends TestRerankBase {assertJQ("/query" + query.toQueryString(), "/response/docs/[3]/fv=='"+docs3fv_default_csv+"'");}- @SuppressWarnings("unchecked")@Testpublic void test1NoMatchFeatureReturnsFvWith1MatchingFeatureFromStoreAndDocWith0Score() throws Exception {// Tests model with all no matching features, but 1 feature store feature matching for extractiondiff --git a/solr/contrib/ltr/src/test/org/apache/solr/ltr/feature/TestOriginalScoreFeature.java b/solr/contrib/ltr/src/test/org/apache/solr/ltr/feature/TestOriginalScoreFeature.javaindex b3e005a196e..8ff56842605 100644--- a/solr/contrib/ltr/src/test/org/apache/solr/ltr/feature/TestOriginalScoreFeature.java+++ b/solr/contrib/ltr/src/test/org/apache/solr/ltr/feature/TestOriginalScoreFeature.java@@ -75,7 +75,6 @@ public class TestOriginalScoreFeature extends TestRerankBase {implTestOriginalScoreResponseDocsCheck("origScore", "origScore", "c2", "2.0");}- @SuppressWarnings("unchecked")public static void implTestOriginalScoreResponseDocsCheck(String modelName,String origScoreFeatureName,String nonScoringFeatureName, String nonScoringFeatureValue) throws Exception {diff --git a/solr/contrib/ltr/src/test/org/apache/solr/ltr/model/TestNeuralNetworkModel.java b/solr/contrib/ltr/src/test/org/apache/solr/ltr/model/TestNeuralNetworkModel.javaindex 9b0bbe861e3..045c625a218 100644--- a/solr/contrib/ltr/src/test/org/apache/solr/ltr/model/TestNeuralNetworkModel.java+++ b/solr/contrib/ltr/src/test/org/apache/solr/ltr/model/TestNeuralNetworkModel.java@@ -314,7 +314,6 @@ public class TestNeuralNetworkModel extends TestRerankBase {}}- @SuppressWarnings("unchecked")@Overrideprotected Layer createLayer(Object o) {final DefaultLayer layer = new DefaultLayer();diff --git a/solr/contrib/ltr/src/test/org/apache/solr/ltr/store/rest/TestModelManagerPersistence.java b/solr/contrib/ltr/src/test/org/apache/solr/ltr/store/rest/TestModelManagerPersistence.javaindex ad33b0a0eae..0e829e68d95 100644--- a/solr/contrib/ltr/src/test/org/apache/solr/ltr/store/rest/TestModelManagerPersistence.java+++ b/solr/contrib/ltr/src/test/org/apache/solr/ltr/store/rest/TestModelManagerPersistence.java@@ -51,7 +51,6 @@ public class TestModelManagerPersistence extends TestRerankBase {}// executed first- @SuppressWarnings("unchecked")@Testpublic void testFeaturePersistence() throws Exception {diff --git a/solr/contrib/prometheus-exporter/src/java/org/apache/solr/prometheus/exporter/MetricsQuery.java b/solr/contrib/prometheus-exporter/src/java/org/apache/solr/prometheus/exporter/MetricsQuery.javaindex 621ef5cb61b..9e79f7db1e4 100644--- a/solr/contrib/prometheus-exporter/src/java/org/apache/solr/prometheus/exporter/MetricsQuery.java+++ b/solr/contrib/prometheus-exporter/src/java/org/apache/solr/prometheus/exporter/MetricsQuery.java@@ -88,7 +88,6 @@ public class MetricsQuery {return jsonQueries;}- @SuppressWarnings({"rawtypes", "unchecked"})public static List<MetricsQuery> from(Node node) throws JsonQueryException {List<MetricsQuery> metricsQueries = new ArrayList<>();diff --git a/solr/contrib/prometheus-exporter/src/java/org/apache/solr/prometheus/exporter/PrometheusExporterSettings.java b/solr/contrib/prometheus-exporter/src/java/org/apache/solr/prometheus/exporter/PrometheusExporterSettings.javaindex 12214c91f03..85f0ec8362f 100644--- a/solr/contrib/prometheus-exporter/src/java/org/apache/solr/prometheus/exporter/PrometheusExporterSettings.java+++ b/solr/contrib/prometheus-exporter/src/java/org/apache/solr/prometheus/exporter/PrometheusExporterSettings.java@@ -56,13 +56,11 @@ public class PrometheusExporterSettings {}- @SuppressWarnings("rawtypes")public static PrometheusExporterSettings from(Node settings) {NamedList config = DOMUtil.childNodesToNamedList(settings);Builder builder = builder();- @SuppressWarnings("unchecked")List<NamedList> httpClientSettings = config.getAll("httpClients");for (NamedList entry : httpClientSettings) {diff --git a/solr/contrib/prometheus-exporter/src/test/org/apache/solr/prometheus/exporter/SolrExporterTestBase.java b/solr/contrib/prometheus-exporter/src/test/org/apache/solr/prometheus/exporter/SolrExporterTestBase.javaindex 6d6954f118c..a390be1f62f 100644--- a/solr/contrib/prometheus-exporter/src/test/org/apache/solr/prometheus/exporter/SolrExporterTestBase.java+++ b/solr/contrib/prometheus-exporter/src/test/org/apache/solr/prometheus/exporter/SolrExporterTestBase.java@@ -47,7 +47,6 @@ public class SolrExporterTestBase extends PrometheusExporterTestBase {private CloseableHttpClient httpClient;private int promtheusExporterPort;- @SuppressWarnings("deprecation")@Override@Afterpublic void tearDown() throws Exception {diff --git a/solr/contrib/velocity/src/java/org/apache/solr/response/VelocityResponseWriter.java b/solr/contrib/velocity/src/java/org/apache/solr/response/VelocityResponseWriter.javaindex 92aec88d566..6279ee3dd11 100644--- a/solr/contrib/velocity/src/java/org/apache/solr/response/VelocityResponseWriter.java+++ b/solr/contrib/velocity/src/java/org/apache/solr/response/VelocityResponseWriter.java@@ -18,6 +18,7 @@ package org.apache.solr.response;import java.io.File;import java.io.IOException;+import java.io.InputStream;import java.io.InputStreamReader;import java.io.StringWriter;import java.io.Writer;@@ -57,7 +58,6 @@ import org.slf4j.LoggerFactory;import static org.apache.solr.common.params.CommonParams.SORT;-@SuppressWarnings("rawtypes")public class VelocityResponseWriter implements QueryResponseWriter, SolrCoreAware {// init param names, these are _only_ loaded at init time (no per-request control of these)// - multiple different named writers could be created with different init params@@ -128,6 +128,7 @@ public class VelocityResponseWriter implements QueryResponseWriter, SolrCoreAwarpublic void inform(SolrCore core) {// need to leverage SolrResourceLoader, so load init.properties.file here instead of init()if (initPropertiesFileName != null) {+ InputStream is = null;try {velocityInitProps.load(new InputStreamReader(core.getResourceLoader().openResource(initPropertiesFileName), StandardCharsets.UTF_8));} catch (IOException e) {@@ -194,7 +195,6 @@ public class VelocityResponseWriter implements QueryResponseWriter, SolrCoreAwar}}- @SuppressWarnings("unchecked")private VelocityContext createContext(SolrQueryRequest request, SolrQueryResponse response) {VelocityContext context = new VelocityContext();diff --git a/solr/core/src/java/org/apache/solr/cloud/ElectionContext.java b/solr/core/src/java/org/apache/solr/cloud/ElectionContext.javaindex 2e2c6d05753..456daeead3f 100644--- a/solr/core/src/java/org/apache/solr/cloud/ElectionContext.java+++ b/solr/core/src/java/org/apache/solr/cloud/ElectionContext.java@@ -19,13 +19,13 @@ package org.apache.solr.cloud;import java.io.Closeable;import java.io.IOException;import java.lang.invoke.MethodHandles;-import java.nio.file.Paths;import java.util.ArrayList;import java.util.EnumSet;import java.util.List;import java.util.concurrent.Future;import java.util.concurrent.TimeUnit;+import org.apache.hadoop.fs.Path;import org.apache.lucene.search.MatchAllDocsQuery;import org.apache.solr.cloud.overseer.OverseerAction;import org.apache.solr.common.SolrException;@@ -137,7 +137,7 @@ class ShardLeaderElectionContextBase extends ElectionContext {this.shardId = shardId;this.collection = collection;- String parent = Paths.get(leaderPath).getParent().toString();+ String parent = new Path(leaderPath).getParent().toString();ZkCmdExecutor zcmd = new ZkCmdExecutor(30000);// only if /collections/{collection} exists already do we succeed in creating this pathlog.info("make sure parent is created {}", parent);@@ -163,7 +163,7 @@ class ShardLeaderElectionContextBase extends ElectionContext {// version whenever a leader registers.log.debug("Removing leader registration node on cancel: {} {}", leaderPath, leaderZkNodeParentVersion);List<Op> ops = new ArrayList<>(2);- ops.add(Op.check(Paths.get(leaderPath).getParent().toString(), leaderZkNodeParentVersion));+ ops.add(Op.check(new Path(leaderPath).getParent().toString(), leaderZkNodeParentVersion));ops.add(Op.delete(leaderPath, -1));zkClient.multi(ops, true);} catch (KeeperException.NoNodeException nne) {@@ -189,7 +189,7 @@ class ShardLeaderElectionContextBase extends ElectionContext {throws KeeperException, InterruptedException, IOException {// register as leader - if an ephemeral is already there, wait to see if it goes away- String parent = Paths.get(leaderPath).getParent().toString();+ String parent = new Path(leaderPath).getParent().toString();try {RetryUtil.retryOnThrowable(NodeExistsException.class, 60000, 5000, () -> {synchronized (lock) {diff --git a/solr/core/src/java/org/apache/solr/legacy/BBoxValueSource.java b/solr/core/src/java/org/apache/solr/legacy/BBoxValueSource.javaindex 31064117c74..516f20714db 100644--- a/solr/core/src/java/org/apache/solr/legacy/BBoxValueSource.java+++ b/solr/core/src/java/org/apache/solr/legacy/BBoxValueSource.java@@ -46,7 +46,6 @@ class BBoxValueSource extends ShapeValuesSource {return "bboxShape(" + strategy.getFieldName() + ")";}- @SuppressWarnings("deprecation")@Overridepublic ShapeValues getValues(LeafReaderContext readerContext) throws IOException {diff --git a/solr/core/src/java/org/apache/solr/parser/CharStream.java b/solr/core/src/java/org/apache/solr/parser/CharStream.javaindex 0400af47e05..9bec5a6e9d5 100644--- a/solr/core/src/java/org/apache/solr/parser/CharStream.java+++ b/solr/core/src/java/org/apache/solr/parser/CharStream.java@@ -27,22 +27,6 @@ interface CharStream {*/char readChar() throws java.io.IOException;- @Deprecated- /**- * Returns the column position of the character last read.- * @deprecated- * @see #getEndColumn- */- int getColumn();-- @Deprecated- /**- * Returns the line number of the character last read.- * @deprecated- * @see #getEndLine- */- int getLine();-/*** Returns the column number of the last character for current token (being* matched after the last call to BeginTOken).diff --git a/solr/core/src/java/org/apache/solr/parser/FastCharStream.java b/solr/core/src/java/org/apache/solr/parser/FastCharStream.javaindex bc5d815d2ec..b9cb27abd9d 100644--- a/solr/core/src/java/org/apache/solr/parser/FastCharStream.java+++ b/solr/core/src/java/org/apache/solr/parser/FastCharStream.java@@ -126,26 +126,4 @@ public final class FastCharStream implements CharStream {public final int getBeginLine() {return 1;}-- @Override- @Deprecated- /**- * Returns the column position of the character last read.- * @deprecated- * @see #getEndColumn- */- public int getColumn() {- return 1;- }-- @Override- @Deprecated- /**- * Returns the line number of the character last read.- * @deprecated- * @see #getEndLine- */- public int getLine() {- return 1;- }}diff --git a/solr/core/src/java/org/apache/solr/parser/QueryParserTokenManager.java b/solr/core/src/java/org/apache/solr/parser/QueryParserTokenManager.javaindex b98a45d2969..16676431a1f 100644--- a/solr/core/src/java/org/apache/solr/parser/QueryParserTokenManager.java+++ b/solr/core/src/java/org/apache/solr/parser/QueryParserTokenManager.java@@ -2,12 +2,10 @@package org.apache.solr.parser;/** Token Manager. */-@SuppressWarnings("cast")public class QueryParserTokenManager implements QueryParserConstants{int commentNestingDepth ;-private final int jjStopStringLiteralDfa_3(int pos, long active0){switch (pos)@@ -1330,9 +1328,9 @@ private int jjMoveNfa_1(int startState, int curPos)}}static final int[] jjnextStates = {- 32, 34, 35, 31, 36, 17, 18, 20, 56, 59, 25, 60, 57, 59, 25, 60,- 22, 23, 38, 39, 46, 38, 39, 40, 46, 38, 39, 41, 49, 54, 46, 42,- 43, 45, 50, 51, 53, 38, 39, 54, 46, 58, 61, 29, 2, 4, 5,+ 32, 34, 35, 31, 36, 17, 18, 20, 56, 59, 25, 60, 57, 59, 25, 60,+ 22, 23, 38, 39, 46, 38, 39, 40, 46, 38, 39, 41, 49, 54, 46, 42,+ 43, 45, 50, 51, 53, 38, 39, 54, 46, 58, 61, 29, 2, 4, 5,};private static final boolean jjCanMove_0(int hiByte, int i1, int i2, long l1, long l2){@@ -1373,9 +1371,9 @@ private static final boolean jjCanMove_2(int hiByte, int i1, int i2, long l1, lo/** Token literal values. */public static final String[] jjstrLiteralImages = {-"", null, null, null, null, null, null, null, null, null, null, null, null,-null, null, null, "\53", "\55", null, "\50", "\51", "\72", "\52", "\136", null, null,-null, null, null, null, "\133", "\173", null, "\146\151\154\164\145\162\50", null,+"", null, null, null, null, null, null, null, null, null, null, null, null,+null, null, null, "\53", "\55", null, "\50", "\51", "\72", "\52", "\136", null, null,+null, null, null, null, "\133", "\173", null, "\146\151\154\164\145\162\50", null,"\124\117", "\135", "\175", null, null, };/** Lexer state names. */@@ -1388,14 +1386,14 @@ public static final String[] lexStateNames = {/** Lex State array. */public static final int[] jjnewLexState = {- -1, -1, -1, -1, -1, -1, -1, -1, -1, 2, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 0, -1,- -1, -1, -1, -1, -1, 1, 1, -1, -1, 3, -1, 3, 3, -1, -1,+ -1, -1, -1, -1, -1, -1, -1, -1, -1, 2, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 0, -1,+ -1, -1, -1, -1, -1, 1, 1, -1, -1, 3, -1, 3, 3, -1, -1,};static final long[] jjtoToken = {- 0xffffffe001L,+ 0xffffffe001L,};static final long[] jjtoSkip = {- 0x1f00L,+ 0x1f00L,};protected CharStream input_stream;private final int[] jjrounds = new int[63];@@ -1480,7 +1478,7 @@ int jjmatchedPos;int jjmatchedKind;/** Get the next Token. */-public Token getNextToken()+public Token getNextToken(){Token matchedToken;int curPos = 0;diff --git a/solr/core/src/java/org/apache/solr/update/processor/AbstractDefaultValueUpdateProcessorFactory.java b/solr/core/src/java/org/apache/solr/update/processor/AbstractDefaultValueUpdateProcessorFactory.javaindex 2862d4dae06..2186e2d9ed2 100644--- a/solr/core/src/java/org/apache/solr/update/processor/AbstractDefaultValueUpdateProcessorFactory.java+++ b/solr/core/src/java/org/apache/solr/update/processor/AbstractDefaultValueUpdateProcessorFactory.java@@ -44,6 +44,7 @@ public abstract class AbstractDefaultValueUpdateProcessorFactoryprotected String fieldName = null;+ @SuppressWarnings("unchecked")@Overridepublic void init(NamedList args) {diff --git a/solr/core/src/test/org/apache/hadoop/http/HttpServer2.java b/solr/core/src/test/org/apache/hadoop/http/HttpServer2.javaindex 5e66ff54d35..5962bebe58d 100644--- a/solr/core/src/test/org/apache/hadoop/http/HttpServer2.java+++ b/solr/core/src/test/org/apache/hadoop/http/HttpServer2.java@@ -1459,6 +1459,7 @@ public final class HttpServer2 implements FilterContainer {response.getOutputStream(), false, "UTF-8")) {ReflectionUtils.printThreadInfo(out, "");}+ ReflectionUtils.logThreadInfo(LOG, "jsp requested", 1);}}diff --git a/solr/core/src/test/org/apache/solr/cloud/MoveReplicaHDFSFailoverTest.java b/solr/core/src/test/org/apache/solr/cloud/MoveReplicaHDFSFailoverTest.javaindex 9fc8198af78..f66029b34e9 100644--- a/solr/core/src/test/org/apache/solr/cloud/MoveReplicaHDFSFailoverTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/MoveReplicaHDFSFailoverTest.java@@ -22,8 +22,6 @@ import java.io.IOException;import com.carrotsearch.randomizedtesting.annotations.Nightly;import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;import org.apache.hadoop.hdfs.MiniDFSCluster;-import org.apache.lucene.util.QuickPatchThreadsFilter;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.client.solrj.SolrClient;import org.apache.solr.client.solrj.SolrQuery;import org.apache.solr.client.solrj.SolrServerException;@@ -42,8 +40,6 @@ import org.junit.BeforeClass;import org.junit.Test;@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})@Nightly // test is too long for non nightlydiff --git a/solr/core/src/test/org/apache/solr/cloud/MoveReplicaHDFSTest.java b/solr/core/src/test/org/apache/solr/cloud/MoveReplicaHDFSTest.javaindex 726a8060be6..3d893101dff 100644--- a/solr/core/src/test/org/apache/solr/cloud/MoveReplicaHDFSTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/MoveReplicaHDFSTest.java@@ -22,9 +22,7 @@ import com.carrotsearch.randomizedtesting.annotations.TimeoutSuite;import org.apache.hadoop.hdfs.MiniDFSCluster;import org.apache.lucene.util.LuceneTestCase.AwaitsFix;import org.apache.lucene.util.LuceneTestCase.Slow;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.TimeUnits;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.cloud.hdfs.HdfsTestUtil;import org.apache.solr.util.BadHdfsThreadsFilter;import org.junit.AfterClass;@@ -34,8 +32,6 @@ import org.junit.Test;@Slow@Nightly@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})@TimeoutSuite(millis = TimeUnits.HOUR)diff --git a/solr/core/src/test/org/apache/solr/cloud/SaslZkACLProviderTest.java b/solr/core/src/test/org/apache/solr/cloud/SaslZkACLProviderTest.javaindex ad4fa8ad2fc..4e3d62e30e2 100644--- a/solr/core/src/test/org/apache/solr/cloud/SaslZkACLProviderTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/SaslZkACLProviderTest.java@@ -23,8 +23,6 @@ import java.nio.charset.Charset;import java.nio.file.Path;import org.apache.lucene.util.Constants;-import org.apache.lucene.util.QuickPatchThreadsFilter;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.SolrTestCaseJ4;import org.apache.solr.common.cloud.DefaultZkACLProvider;import org.apache.solr.common.cloud.SaslZkACLProvider;@@ -42,8 +40,6 @@ import org.slf4j.LoggerFactory;import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadZookeeperThreadsFilter.class})public class SaslZkACLProviderTest extends SolrTestCaseJ4 {diff --git a/solr/core/src/test/org/apache/solr/cloud/SharedFSAutoReplicaFailoverTest.java b/solr/core/src/test/org/apache/solr/cloud/SharedFSAutoReplicaFailoverTest.javaindex 1e0a7befa37..735cc2080d7 100644--- a/solr/core/src/test/org/apache/solr/cloud/SharedFSAutoReplicaFailoverTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/SharedFSAutoReplicaFailoverTest.java@@ -34,11 +34,8 @@ import java.util.stream.Collectors;import org.apache.hadoop.hdfs.MiniDFSCluster;import org.apache.lucene.util.LuceneTestCase;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.LuceneTestCase.Slow;import com.carrotsearch.randomizedtesting.annotations.Nightly;--import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.SolrTestCaseJ4.SuppressSSL;import org.apache.solr.client.solrj.SolrQuery;import org.apache.solr.client.solrj.SolrServerException;@@ -78,8 +75,6 @@ import org.slf4j.LoggerFactory;@Slow@SuppressSSL@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})@LogLevel("org.apache.solr.cloud.autoscaling=DEBUG;org.apache.solr.cloud.*=DEBUG")diff --git a/solr/core/src/test/org/apache/solr/cloud/TestSolrCloudWithKerberosAlt.java b/solr/core/src/test/org/apache/solr/cloud/TestSolrCloudWithKerberosAlt.javaindex 9d03331b645..9ceb826de9e 100644--- a/solr/core/src/test/org/apache/solr/cloud/TestSolrCloudWithKerberosAlt.java+++ b/solr/core/src/test/org/apache/solr/cloud/TestSolrCloudWithKerberosAlt.java@@ -25,8 +25,6 @@ import com.carrotsearch.randomizedtesting.annotations.ThreadLeakLingering;import org.apache.commons.io.FileUtils;import org.apache.lucene.util.LuceneTestCase;-import org.apache.lucene.util.QuickPatchThreadsFilter;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.client.solrj.SolrQuery;import org.apache.solr.client.solrj.impl.CloudSolrClient;import org.apache.solr.client.solrj.request.CollectionAdminRequest;@@ -41,8 +39,6 @@ import org.slf4j.LoggerFactory;* Test 5 nodes Solr cluster with Kerberos plugin enabled.*/@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadZookeeperThreadsFilter.class // Zookeeper login leaks TGT renewal threads})diff --git a/solr/core/src/test/org/apache/solr/cloud/api/collections/HdfsCollectionsAPIDistributedZkTest.java b/solr/core/src/test/org/apache/solr/cloud/api/collections/HdfsCollectionsAPIDistributedZkTest.javaindex 614fd8b7b1c..94b3102f0c8 100644--- a/solr/core/src/test/org/apache/solr/cloud/api/collections/HdfsCollectionsAPIDistributedZkTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/api/collections/HdfsCollectionsAPIDistributedZkTest.java@@ -21,9 +21,7 @@ import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;import com.carrotsearch.randomizedtesting.annotations.TimeoutSuite;import org.apache.hadoop.hdfs.MiniDFSCluster;import org.apache.lucene.util.LuceneTestCase.Slow;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.TimeUnits;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.cloud.hdfs.HdfsTestUtil;import org.apache.solr.util.BadHdfsThreadsFilter;import org.junit.AfterClass;@@ -32,8 +30,6 @@ import org.junit.BeforeClass;@Slow@Nightly@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})@TimeoutSuite(millis = TimeUnits.HOUR)diff --git a/solr/core/src/test/org/apache/solr/cloud/api/collections/TestHdfsCloudBackupRestore.java b/solr/core/src/test/org/apache/solr/cloud/api/collections/TestHdfsCloudBackupRestore.javaindex b646e71cbce..27a187e02e6 100644--- a/solr/core/src/test/org/apache/solr/cloud/api/collections/TestHdfsCloudBackupRestore.java+++ b/solr/core/src/test/org/apache/solr/cloud/api/collections/TestHdfsCloudBackupRestore.java@@ -26,8 +26,6 @@ import java.util.HashMap;import java.util.Map;import java.util.Properties;-import org.apache.lucene.util.QuickPatchThreadsFilter;-import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;import org.apache.commons.io.IOUtils;import org.apache.hadoop.conf.Configuration;@@ -36,7 +34,6 @@ import org.apache.hadoop.fs.Path;import org.apache.hadoop.hdfs.DistributedFileSystem;import org.apache.hadoop.hdfs.MiniDFSCluster;import org.apache.hadoop.hdfs.protocol.HdfsConstants.SafeModeAction;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.client.solrj.impl.CloudSolrClient;import org.apache.solr.client.solrj.request.CollectionAdminRequest;import org.apache.solr.cloud.hdfs.HdfsTestUtil;@@ -64,8 +61,6 @@ import static org.apache.solr.core.backup.BackupManager.ZK_STATE_DIR;* This class implements the tests for HDFS integration for Solr backup/restore capability.*/@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})public class TestHdfsCloudBackupRestore extends AbstractCloudBackupRestoreTestCase {diff --git a/solr/core/src/test/org/apache/solr/cloud/autoscaling/HdfsAutoAddReplicasIntegrationTest.java b/solr/core/src/test/org/apache/solr/cloud/autoscaling/HdfsAutoAddReplicasIntegrationTest.javaindex 7600bf46cc7..8d8ef9c76c5 100644--- a/solr/core/src/test/org/apache/solr/cloud/autoscaling/HdfsAutoAddReplicasIntegrationTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/autoscaling/HdfsAutoAddReplicasIntegrationTest.java@@ -21,9 +21,7 @@ import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;import com.carrotsearch.randomizedtesting.annotations.TimeoutSuite;import org.apache.hadoop.hdfs.MiniDFSCluster;import org.apache.lucene.util.LuceneTestCase.Slow;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.TimeUnits;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.cloud.hdfs.HdfsTestUtil;import org.apache.solr.util.BadHdfsThreadsFilter;import org.junit.AfterClass;@@ -32,8 +30,6 @@ import org.junit.BeforeClass;@Slow@Nightly@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})@TimeoutSuite(millis = TimeUnits.HOUR)diff --git a/solr/core/src/test/org/apache/solr/cloud/hdfs/HDFSCollectionsAPITest.java b/solr/core/src/test/org/apache/solr/cloud/hdfs/HDFSCollectionsAPITest.javaindex cf43b6aaa32..6a93042e960 100644--- a/solr/core/src/test/org/apache/solr/cloud/hdfs/HDFSCollectionsAPITest.java+++ b/solr/core/src/test/org/apache/solr/cloud/hdfs/HDFSCollectionsAPITest.java@@ -19,8 +19,6 @@ package org.apache.solr.cloud.hdfs;import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;import org.apache.hadoop.hdfs.MiniDFSCluster;-import org.apache.lucene.util.QuickPatchThreadsFilter;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.client.solrj.SolrQuery;import org.apache.solr.client.solrj.embedded.JettySolrRunner;import org.apache.solr.client.solrj.request.CollectionAdminRequest;@@ -34,8 +32,6 @@ import org.junit.AfterClass;import org.junit.BeforeClass;@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})public class HDFSCollectionsAPITest extends SolrCloudTestCase {diff --git a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsBasicDistributedZk2Test.java b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsBasicDistributedZk2Test.javaindex 599ecbbe418..0c7081b3f39 100644--- a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsBasicDistributedZk2Test.java+++ b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsBasicDistributedZk2Test.java@@ -19,9 +19,7 @@ package org.apache.solr.cloud.hdfs;import java.io.IOException;import org.apache.hadoop.hdfs.MiniDFSCluster;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.LuceneTestCase.Slow;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.cloud.BasicDistributedZk2Test;import org.apache.solr.util.BadHdfsThreadsFilter;import org.junit.AfterClass;@@ -33,8 +31,6 @@ import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;@Slow@Nightly@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})// commented 20-July-2018 @LuceneTestCase.BadApple(bugUrl="https://issues.apache.org/jira/browse/SOLR-12028") // 26-Mar-2018diff --git a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsBasicDistributedZkTest.java b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsBasicDistributedZkTest.javaindex bc172b3150c..192e7ee13d0 100644--- a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsBasicDistributedZkTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsBasicDistributedZkTest.java@@ -19,9 +19,7 @@ package org.apache.solr.cloud.hdfs;import java.io.IOException;import org.apache.hadoop.hdfs.MiniDFSCluster;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.LuceneTestCase.Slow;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.cloud.BasicDistributedZkTest;import org.apache.solr.util.BadHdfsThreadsFilter;import org.junit.AfterClass;@@ -33,8 +31,6 @@ import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;@Slow@Nightly@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})public class HdfsBasicDistributedZkTest extends BasicDistributedZkTest {diff --git a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsChaosMonkeyNothingIsSafeTest.java b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsChaosMonkeyNothingIsSafeTest.javaindex 94ace06c786..3bdf77a114e 100644--- a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsChaosMonkeyNothingIsSafeTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsChaosMonkeyNothingIsSafeTest.java@@ -19,9 +19,7 @@ package org.apache.solr.cloud.hdfs;import java.io.IOException;import org.apache.hadoop.hdfs.MiniDFSCluster;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.LuceneTestCase.Slow;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.cloud.ChaosMonkeyNothingIsSafeTest;import org.apache.solr.util.BadHdfsThreadsFilter;import org.junit.AfterClass;@@ -33,8 +31,6 @@ import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;@Slow@Nightly@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})public class HdfsChaosMonkeyNothingIsSafeTest extends ChaosMonkeyNothingIsSafeTest {diff --git a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsChaosMonkeySafeLeaderTest.java b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsChaosMonkeySafeLeaderTest.javaindex 402d5cf07c6..ab5eb33c97a 100644--- a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsChaosMonkeySafeLeaderTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsChaosMonkeySafeLeaderTest.java@@ -19,9 +19,7 @@ package org.apache.solr.cloud.hdfs;import java.io.IOException;import org.apache.hadoop.hdfs.MiniDFSCluster;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.LuceneTestCase.Slow;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.cloud.ChaosMonkeySafeLeaderTest;import org.apache.solr.util.BadHdfsThreadsFilter;import org.junit.AfterClass;@@ -33,8 +31,6 @@ import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;@Slow@Nightly@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})public class HdfsChaosMonkeySafeLeaderTest extends ChaosMonkeySafeLeaderTest {diff --git a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsNNFailoverTest.java b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsNNFailoverTest.javaindex b76e69a6410..d793852aab1 100644--- a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsNNFailoverTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsNNFailoverTest.java@@ -19,9 +19,7 @@ package org.apache.solr.cloud.hdfs;import java.io.IOException;import org.apache.hadoop.hdfs.MiniDFSCluster;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.LuceneTestCase.Slow;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.cloud.BasicDistributedZkTest;import org.apache.solr.util.BadHdfsThreadsFilter;import org.junit.AfterClass;@@ -32,8 +30,6 @@ import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;@Slow@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})public class HdfsNNFailoverTest extends BasicDistributedZkTest {diff --git a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsRecoverLeaseTest.java b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsRecoverLeaseTest.javaindex 84aee374588..ad8556cf0ca 100644--- a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsRecoverLeaseTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsRecoverLeaseTest.java@@ -26,8 +26,6 @@ import org.apache.hadoop.fs.FSDataOutputStream;import org.apache.hadoop.fs.FileSystem;import org.apache.hadoop.fs.Path;import org.apache.hadoop.hdfs.MiniDFSCluster;-import org.apache.lucene.util.QuickPatchThreadsFilter;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.SolrTestCaseJ4;import org.apache.solr.util.BadHdfsThreadsFilter;import org.apache.solr.util.FSHDFSUtils;@@ -41,8 +39,6 @@ import org.junit.Test;import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})public class HdfsRecoverLeaseTest extends SolrTestCaseJ4 {diff --git a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsRecoveryZkTest.java b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsRecoveryZkTest.javaindex d040faec89a..a797abd769f 100644--- a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsRecoveryZkTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsRecoveryZkTest.java@@ -18,10 +18,8 @@ package org.apache.solr.cloud.hdfs;import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;import org.apache.hadoop.hdfs.MiniDFSCluster;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.LuceneTestCase.Nightly;import org.apache.lucene.util.LuceneTestCase.Slow;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.cloud.RecoveryZkTest;import org.apache.solr.common.cloud.ZkConfigManager;import org.apache.solr.util.BadHdfsThreadsFilter;@@ -31,8 +29,6 @@ import org.junit.BeforeClass;@Slow@Nightly@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})public class HdfsRecoveryZkTest extends RecoveryZkTest {diff --git a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsRestartWhileUpdatingTest.java b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsRestartWhileUpdatingTest.javaindex ebc6068d502..64af1091996 100644--- a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsRestartWhileUpdatingTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsRestartWhileUpdatingTest.java@@ -17,9 +17,7 @@package org.apache.solr.cloud.hdfs;import org.apache.hadoop.hdfs.MiniDFSCluster;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.LuceneTestCase.Slow;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.cloud.RestartWhileUpdatingTest;import org.apache.solr.util.BadHdfsThreadsFilter;import org.junit.AfterClass;@@ -31,8 +29,6 @@ import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;@Slow@Nightly@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})public class HdfsRestartWhileUpdatingTest extends RestartWhileUpdatingTest {diff --git a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsSyncSliceTest.java b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsSyncSliceTest.javaindex 785ae6f9c6c..49998472f46 100644--- a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsSyncSliceTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsSyncSliceTest.java@@ -19,9 +19,7 @@ package org.apache.solr.cloud.hdfs;import java.io.IOException;import org.apache.hadoop.hdfs.MiniDFSCluster;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.LuceneTestCase.Slow;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.cloud.SyncSliceTest;import org.apache.solr.util.BadHdfsThreadsFilter;import org.junit.AfterClass;@@ -33,8 +31,6 @@ import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;@Slow@Nightly@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})// commented out on: 24-Dec-2018 @LuceneTestCase.BadApple(bugUrl="https://issues.apache.org/jira/browse/SOLR-12028") // 12-Jun-2018diff --git a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsThreadLeakTest.java b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsThreadLeakTest.javaindex 2e04ee04dc0..f250d53f46a 100644--- a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsThreadLeakTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsThreadLeakTest.java@@ -23,8 +23,6 @@ import org.apache.hadoop.fs.FileSystem;import org.apache.hadoop.fs.Path;import org.apache.hadoop.hdfs.DistributedFileSystem;import org.apache.hadoop.hdfs.MiniDFSCluster;-import org.apache.lucene.util.QuickPatchThreadsFilter;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.SolrTestCaseJ4;import org.apache.solr.util.BadHdfsThreadsFilter;import org.junit.AfterClass;@@ -34,8 +32,6 @@ import org.junit.Test;import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})public class HdfsThreadLeakTest extends SolrTestCaseJ4 {diff --git a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsTlogReplayBufferedWhileIndexingTest.java b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsTlogReplayBufferedWhileIndexingTest.javaindex 42cfcaa255a..ff19b090d16 100644--- a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsTlogReplayBufferedWhileIndexingTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsTlogReplayBufferedWhileIndexingTest.java@@ -17,9 +17,7 @@package org.apache.solr.cloud.hdfs;import org.apache.hadoop.hdfs.MiniDFSCluster;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.LuceneTestCase.Slow;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.cloud.TlogReplayBufferedWhileIndexingTest;import org.apache.solr.util.BadHdfsThreadsFilter;import org.junit.AfterClass;@@ -31,8 +29,6 @@ import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;@Slow@Nightly@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})public class HdfsTlogReplayBufferedWhileIndexingTest extends TlogReplayBufferedWhileIndexingTest {diff --git a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsUnloadDistributedZkTest.java b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsUnloadDistributedZkTest.javaindex 59440976280..0d3d23ea646 100644--- a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsUnloadDistributedZkTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsUnloadDistributedZkTest.java@@ -17,9 +17,7 @@package org.apache.solr.cloud.hdfs;import org.apache.hadoop.hdfs.MiniDFSCluster;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.LuceneTestCase.Slow;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.cloud.UnloadDistributedZkTest;import org.apache.solr.util.BadHdfsThreadsFilter;import org.junit.AfterClass;@@ -31,8 +29,6 @@ import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;@Slow@Nightly@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})public class HdfsUnloadDistributedZkTest extends UnloadDistributedZkTest {diff --git a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsWriteToMultipleCollectionsTest.java b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsWriteToMultipleCollectionsTest.javaindex 6086c59c27a..1f316033785 100644--- a/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsWriteToMultipleCollectionsTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/hdfs/HdfsWriteToMultipleCollectionsTest.java@@ -31,10 +31,8 @@ import org.apache.lucene.index.IndexWriter;import org.apache.lucene.store.Directory;import org.apache.lucene.store.NRTCachingDirectory;import org.apache.lucene.util.IOUtils;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.LuceneTestCase.Nightly;import org.apache.lucene.util.LuceneTestCase.Slow;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.client.solrj.SolrQuery;import org.apache.solr.client.solrj.embedded.JettySolrRunner;import org.apache.solr.client.solrj.impl.CloudSolrClient;@@ -57,8 +55,6 @@ import org.junit.Test;@Slow@Nightly@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})public class HdfsWriteToMultipleCollectionsTest extends BasicDistributedZkTest {diff --git a/solr/core/src/test/org/apache/solr/cloud/hdfs/StressHdfsTest.java b/solr/core/src/test/org/apache/solr/cloud/hdfs/StressHdfsTest.javaindex a12d4b911c5..04f93875f9b 100644--- a/solr/core/src/test/org/apache/solr/cloud/hdfs/StressHdfsTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/hdfs/StressHdfsTest.java@@ -24,9 +24,7 @@ import org.apache.hadoop.fs.FileSystem;import org.apache.hadoop.fs.Path;import org.apache.hadoop.hdfs.MiniDFSCluster;import org.apache.hadoop.hdfs.server.namenode.NameNodeAdapter;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.LuceneTestCase.Slow;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.client.solrj.SolrClient;import org.apache.solr.client.solrj.SolrQuery;import org.apache.solr.client.solrj.impl.HttpSolrClient;@@ -58,8 +56,6 @@ import java.util.concurrent.TimeUnit;@Slow@Nightly@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})public class StressHdfsTest extends BasicDistributedZkTest {diff --git a/solr/core/src/test/org/apache/solr/core/HdfsDirectoryFactoryTest.java b/solr/core/src/test/org/apache/solr/core/HdfsDirectoryFactoryTest.javaindex 3f1e41c150b..632fcb68b82 100644--- a/solr/core/src/test/org/apache/solr/core/HdfsDirectoryFactoryTest.java+++ b/solr/core/src/test/org/apache/solr/core/HdfsDirectoryFactoryTest.java@@ -34,9 +34,7 @@ import org.apache.hadoop.hdfs.MiniDFSCluster;import org.apache.lucene.store.Directory;import org.apache.lucene.store.IndexOutput;import org.apache.lucene.store.NoLockFactory;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.TestUtil;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.SolrTestCaseJ4;import org.apache.solr.cloud.hdfs.HdfsTestUtil;import org.apache.solr.common.util.NamedList;@@ -55,8 +53,6 @@ import org.junit.Test;import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})public class HdfsDirectoryFactoryTest extends SolrTestCaseJ4 {diff --git a/solr/core/src/test/org/apache/solr/handler/TestHdfsBackupRestoreCore.java b/solr/core/src/test/org/apache/solr/handler/TestHdfsBackupRestoreCore.javaindex 010cc8b859b..fc7a58e436c 100644--- a/solr/core/src/test/org/apache/solr/handler/TestHdfsBackupRestoreCore.java+++ b/solr/core/src/test/org/apache/solr/handler/TestHdfsBackupRestoreCore.java@@ -33,9 +33,7 @@ import org.apache.hadoop.fs.permission.FsPermission;import org.apache.hadoop.hdfs.DistributedFileSystem;import org.apache.hadoop.hdfs.MiniDFSCluster;import org.apache.hadoop.hdfs.protocol.HdfsConstants.SafeModeAction;-import org.apache.lucene.util.QuickPatchThreadsFilter;import org.apache.lucene.util.TestUtil;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.SolrTestCaseJ4;import org.apache.solr.client.solrj.impl.CloudSolrClient;import org.apache.solr.client.solrj.impl.HttpSolrClient;@@ -59,8 +57,6 @@ import org.slf4j.LoggerFactory;import static org.apache.solr.common.cloud.ZkStateReader.BASE_URL_PROP;@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})@SolrTestCaseJ4.SuppressSSL // Currently unknown why SSL does not work with this testdiff --git a/solr/core/src/test/org/apache/solr/index/hdfs/CheckHdfsIndexTest.java b/solr/core/src/test/org/apache/solr/index/hdfs/CheckHdfsIndexTest.javaindex bd54cf17f46..8eefd9a3662 100644--- a/solr/core/src/test/org/apache/solr/index/hdfs/CheckHdfsIndexTest.java+++ b/solr/core/src/test/org/apache/solr/index/hdfs/CheckHdfsIndexTest.java@@ -24,8 +24,6 @@ import org.apache.hadoop.fs.Path;import org.apache.hadoop.hdfs.MiniDFSCluster;import org.apache.lucene.index.BaseTestCheckIndex;import org.apache.lucene.store.Directory;-import org.apache.lucene.util.QuickPatchThreadsFilter;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.client.solrj.SolrClient;import org.apache.solr.client.solrj.SolrQuery;import org.apache.solr.cloud.AbstractFullDistribZkTestBase;@@ -43,8 +41,6 @@ import org.junit.Test;import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})// commented out on: 24-Dec-2018 @LuceneTestCase.BadApple(bugUrl="https://issues.apache.org/jira/browse/SOLR-12028") // 12-Jun-2018diff --git a/solr/core/src/test/org/apache/solr/search/QueryEqualityTest.java b/solr/core/src/test/org/apache/solr/search/QueryEqualityTest.javaindex 2fc63070fba..956275db665 100644--- a/solr/core/src/test/org/apache/solr/search/QueryEqualityTest.java+++ b/solr/core/src/test/org/apache/solr/search/QueryEqualityTest.java@@ -20,6 +20,7 @@ import java.util.HashSet;import java.util.Map;import java.util.Set;+import junit.framework.AssertionFailedError;import org.apache.lucene.search.Query;import org.apache.lucene.search.QueryUtils;import org.apache.solr.SolrTestCaseJ4;@@ -1224,7 +1225,7 @@ public class QueryEqualityTest extends SolrTestCaseJ4 {public void testPayloadScoreQuery() throws Exception {// There was a bug with PayloadScoreQuery's .equals() method that said two queries were equal with different includeSpanScore settings- expectThrows(AssertionError.class, "queries should not have been equal",+ expectThrows(AssertionFailedError.class, "queries should not have been equal",() -> assertQueryEquals("payload_score", "{!payload_score f=foo_dpf v=query func=min includeSpanScore=false}"@@ -1234,7 +1235,7 @@ public class QueryEqualityTest extends SolrTestCaseJ4 {}public void testPayloadCheckQuery() throws Exception {- expectThrows(AssertionError.class, "queries should not have been equal",+ expectThrows(AssertionFailedError.class, "queries should not have been equal",() -> assertQueryEquals("payload_check", "{!payload_check f=foo_dpf payloads=2}one"@@ -1265,7 +1266,7 @@ public class QueryEqualityTest extends SolrTestCaseJ4 {"{!bool must='{!lucene}foo_s:c' filter='{!lucene}foo_s:d' " +"must_not='{!lucene}foo_s:a' should='{!lucene}foo_s:b' filter='{!lucene}foo_s:e'}");- expectThrows(AssertionError.class, "queries should not have been equal",+ expectThrows(AssertionFailedError.class, "queries should not have been equal",() -> assertQueryEquals("bool", "{!bool must='{!lucene}foo_s:a'}"diff --git a/solr/core/src/test/org/apache/solr/search/TestRecoveryHdfs.java b/solr/core/src/test/org/apache/solr/search/TestRecoveryHdfs.javaindex d0bd2710eb5..e19895e9e53 100644--- a/solr/core/src/test/org/apache/solr/search/TestRecoveryHdfs.java+++ b/solr/core/src/test/org/apache/solr/search/TestRecoveryHdfs.java@@ -39,8 +39,6 @@ import org.apache.hadoop.fs.FileStatus;import org.apache.hadoop.fs.FileSystem;import org.apache.hadoop.fs.Path;import org.apache.hadoop.hdfs.MiniDFSCluster;-import org.apache.lucene.util.QuickPatchThreadsFilter;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.SolrTestCaseJ4;import org.apache.solr.cloud.hdfs.HdfsTestUtil;import org.apache.solr.common.util.IOUtils;@@ -62,8 +60,6 @@ import org.junit.Test;import static org.apache.solr.update.processor.DistributingUpdateProcessorFactory.DISTRIB_UPDATE_PARAM;@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})// TODO: longer term this should be combined with TestRecovery somehow ??diff --git a/solr/core/src/test/org/apache/solr/store/hdfs/HdfsDirectoryTest.java b/solr/core/src/test/org/apache/solr/store/hdfs/HdfsDirectoryTest.javaindex c41c056d391..5e72b522204 100644--- a/solr/core/src/test/org/apache/solr/store/hdfs/HdfsDirectoryTest.java+++ b/solr/core/src/test/org/apache/solr/store/hdfs/HdfsDirectoryTest.java@@ -29,8 +29,6 @@ import org.apache.lucene.store.Directory;import org.apache.lucene.store.IOContext;import org.apache.lucene.store.IndexInput;import org.apache.lucene.store.IndexOutput;-import org.apache.lucene.util.QuickPatchThreadsFilter;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.SolrTestCaseJ4;import org.apache.solr.cloud.hdfs.HdfsTestUtil;import org.apache.solr.util.BadHdfsThreadsFilter;@@ -43,8 +41,6 @@ import org.junit.Test;import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})public class HdfsDirectoryTest extends SolrTestCaseJ4 {diff --git a/solr/core/src/test/org/apache/solr/store/hdfs/HdfsLockFactoryTest.java b/solr/core/src/test/org/apache/solr/store/hdfs/HdfsLockFactoryTest.javaindex 3d8f91eb24d..7a232408891 100644--- a/solr/core/src/test/org/apache/solr/store/hdfs/HdfsLockFactoryTest.java+++ b/solr/core/src/test/org/apache/solr/store/hdfs/HdfsLockFactoryTest.java@@ -23,8 +23,6 @@ import org.apache.hadoop.fs.Path;import org.apache.hadoop.hdfs.MiniDFSCluster;import org.apache.lucene.store.Lock;import org.apache.lucene.store.LockObtainFailedException;-import org.apache.lucene.util.QuickPatchThreadsFilter;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.SolrTestCaseJ4;import org.apache.solr.cloud.hdfs.HdfsTestUtil;import org.apache.solr.util.BadHdfsThreadsFilter;@@ -36,8 +34,6 @@ import com.carrotsearch.randomizedtesting.annotations.Nightly;import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})@Nightlydiff --git a/solr/core/src/test/org/apache/solr/update/TestHdfsUpdateLog.java b/solr/core/src/test/org/apache/solr/update/TestHdfsUpdateLog.javaindex c2c06375be9..5ba7f58ec14 100644--- a/solr/core/src/test/org/apache/solr/update/TestHdfsUpdateLog.java+++ b/solr/core/src/test/org/apache/solr/update/TestHdfsUpdateLog.java@@ -23,8 +23,6 @@ import java.net.URISyntaxException;import org.apache.hadoop.conf.Configuration;import org.apache.hadoop.fs.FileSystem;import org.apache.hadoop.hdfs.MiniDFSCluster;-import org.apache.lucene.util.QuickPatchThreadsFilter;-import org.apache.solr.SolrIgnoredThreadsFilter;import org.apache.solr.SolrTestCaseJ4;import org.apache.solr.cloud.hdfs.HdfsTestUtil;import org.apache.solr.common.util.IOUtils;@@ -37,8 +35,6 @@ import org.junit.Test;import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;@ThreadLeakFilters(defaultFilters = true, filters = {- SolrIgnoredThreadsFilter.class,- QuickPatchThreadsFilter.class,BadHdfsThreadsFilter.class // hdfs currently leaks thread(s)})public class TestHdfsUpdateLog extends SolrTestCaseJ4 {diff --git a/solr/licenses/http2-client-NOTICE.txt b/solr/licenses/http2-client-NOTICE.txtindex b6817e12bc3..e9461a8e86e 100644--- a/solr/licenses/http2-client-NOTICE.txt+++ b/solr/licenses/http2-client-NOTICE.txt@@ -31,18 +31,18 @@ repository ("Repository") in CVS modules ("Modules") and made availableas downloadable archives ("Downloads").</p><ul>- <li>Content may be structured and packaged into modules to+ <li>Content may be structured and packaged into modules tofacilitate delivering, extending, and upgrading the Content. Typicalmodules may include plug-ins ("Plug-ins"), plug-in fragments("Fragments"), and features ("Features").</li>- <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li>- <li>A+ <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li>+ <li>AFeature is a bundle of one or more Plug-ins and/or Fragments andassociated material. Each Feature may be packaged as a sub-directory ina directory named "features". Within a Feature, files named"feature.xml" may contain a list of the names and version numbers ofthe Plug-ins and/or Fragments associated with that Feature.</li>- <li>Features+ <li>Featuresmay also include other Features ("Included Features"). Within aFeature, files named "feature.xml" may contain a list of the names andversion numbers of Included Features.</li>@@ -57,13 +57,13 @@ directory of a Download or Moduleincluding, but not limited to the following locations:</p><ul>- <li>The top-level (root) directory</li>- <li>Plug-in and Fragment directories</li>- <li>Inside Plug-ins and Fragments packaged as JARs</li>- <li>Sub-directories of the directory named "src" of certain Plug-ins</li>- <li>Feature directories</li>+ <li>The top-level (root) directory</li>+ <li>Plug-in and Fragment directories</li>+ <li>Inside Plug-ins and Fragments packaged as JARs</li>+ <li>Sub-directories of the directory named "src" of certain Plug-ins</li>+ <li>Feature directories</li></ul>-+<p>Note: if a Feature made available by the Eclipse Foundation isinstalled using the Eclipse Update Manager, you must agree to a license("Feature Update License") during the@@ -84,12 +84,12 @@ CONDITIONS. SOME OF THESEOTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p><ul>- <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>- <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>- <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>- <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>- <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>- <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li>+ <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>+ <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>+ <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>+ <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>+ <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>+ <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li></ul><p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS ANDdiff --git a/solr/licenses/http2-common-NOTICE.txt b/solr/licenses/http2-common-NOTICE.txtindex b6817e12bc3..e9461a8e86e 100644--- a/solr/licenses/http2-common-NOTICE.txt+++ b/solr/licenses/http2-common-NOTICE.txt@@ -31,18 +31,18 @@ repository ("Repository") in CVS modules ("Modules") and made availableas downloadable archives ("Downloads").</p><ul>- <li>Content may be structured and packaged into modules to+ <li>Content may be structured and packaged into modules tofacilitate delivering, extending, and upgrading the Content. Typicalmodules may include plug-ins ("Plug-ins"), plug-in fragments("Fragments"), and features ("Features").</li>- <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li>- <li>A+ <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li>+ <li>AFeature is a bundle of one or more Plug-ins and/or Fragments andassociated material. Each Feature may be packaged as a sub-directory ina directory named "features". Within a Feature, files named"feature.xml" may contain a list of the names and version numbers ofthe Plug-ins and/or Fragments associated with that Feature.</li>- <li>Features+ <li>Featuresmay also include other Features ("Included Features"). Within aFeature, files named "feature.xml" may contain a list of the names andversion numbers of Included Features.</li>@@ -57,13 +57,13 @@ directory of a Download or Moduleincluding, but not limited to the following locations:</p><ul>- <li>The top-level (root) directory</li>- <li>Plug-in and Fragment directories</li>- <li>Inside Plug-ins and Fragments packaged as JARs</li>- <li>Sub-directories of the directory named "src" of certain Plug-ins</li>- <li>Feature directories</li>+ <li>The top-level (root) directory</li>+ <li>Plug-in and Fragment directories</li>+ <li>Inside Plug-ins and Fragments packaged as JARs</li>+ <li>Sub-directories of the directory named "src" of certain Plug-ins</li>+ <li>Feature directories</li></ul>-+<p>Note: if a Feature made available by the Eclipse Foundation isinstalled using the Eclipse Update Manager, you must agree to a license("Feature Update License") during the@@ -84,12 +84,12 @@ CONDITIONS. SOME OF THESEOTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p><ul>- <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>- <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>- <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>- <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>- <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>- <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li>+ <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>+ <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>+ <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>+ <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>+ <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>+ <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li></ul><p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS ANDdiff --git a/solr/licenses/http2-hpack-NOTICE.txt b/solr/licenses/http2-hpack-NOTICE.txtindex b6817e12bc3..e9461a8e86e 100644--- a/solr/licenses/http2-hpack-NOTICE.txt+++ b/solr/licenses/http2-hpack-NOTICE.txt@@ -31,18 +31,18 @@ repository ("Repository") in CVS modules ("Modules") and made availableas downloadable archives ("Downloads").</p><ul>- <li>Content may be structured and packaged into modules to+ <li>Content may be structured and packaged into modules tofacilitate delivering, extending, and upgrading the Content. Typicalmodules may include plug-ins ("Plug-ins"), plug-in fragments("Fragments"), and features ("Features").</li>- <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li>- <li>A+ <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li>+ <li>AFeature is a bundle of one or more Plug-ins and/or Fragments andassociated material. Each Feature may be packaged as a sub-directory ina directory named "features". Within a Feature, files named"feature.xml" may contain a list of the names and version numbers ofthe Plug-ins and/or Fragments associated with that Feature.</li>- <li>Features+ <li>Featuresmay also include other Features ("Included Features"). Within aFeature, files named "feature.xml" may contain a list of the names andversion numbers of Included Features.</li>@@ -57,13 +57,13 @@ directory of a Download or Moduleincluding, but not limited to the following locations:</p><ul>- <li>The top-level (root) directory</li>- <li>Plug-in and Fragment directories</li>- <li>Inside Plug-ins and Fragments packaged as JARs</li>- <li>Sub-directories of the directory named "src" of certain Plug-ins</li>- <li>Feature directories</li>+ <li>The top-level (root) directory</li>+ <li>Plug-in and Fragment directories</li>+ <li>Inside Plug-ins and Fragments packaged as JARs</li>+ <li>Sub-directories of the directory named "src" of certain Plug-ins</li>+ <li>Feature directories</li></ul>-+<p>Note: if a Feature made available by the Eclipse Foundation isinstalled using the Eclipse Update Manager, you must agree to a license("Feature Update License") during the@@ -84,12 +84,12 @@ CONDITIONS. SOME OF THESEOTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p><ul>- <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>- <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>- <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>- <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>- <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>- <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li>+ <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>+ <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>+ <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>+ <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>+ <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>+ <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li></ul><p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS ANDdiff --git a/solr/licenses/http2-http-client-transport-NOTICE.txt b/solr/licenses/http2-http-client-transport-NOTICE.txtindex b6817e12bc3..e9461a8e86e 100644--- a/solr/licenses/http2-http-client-transport-NOTICE.txt+++ b/solr/licenses/http2-http-client-transport-NOTICE.txt@@ -31,18 +31,18 @@ repository ("Repository") in CVS modules ("Modules") and made availableas downloadable archives ("Downloads").</p><ul>- <li>Content may be structured and packaged into modules to+ <li>Content may be structured and packaged into modules tofacilitate delivering, extending, and upgrading the Content. Typicalmodules may include plug-ins ("Plug-ins"), plug-in fragments("Fragments"), and features ("Features").</li>- <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li>- <li>A+ <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li>+ <li>AFeature is a bundle of one or more Plug-ins and/or Fragments andassociated material. Each Feature may be packaged as a sub-directory ina directory named "features". Within a Feature, files named"feature.xml" may contain a list of the names and version numbers ofthe Plug-ins and/or Fragments associated with that Feature.</li>- <li>Features+ <li>Featuresmay also include other Features ("Included Features"). Within aFeature, files named "feature.xml" may contain a list of the names andversion numbers of Included Features.</li>@@ -57,13 +57,13 @@ directory of a Download or Moduleincluding, but not limited to the following locations:</p><ul>- <li>The top-level (root) directory</li>- <li>Plug-in and Fragment directories</li>- <li>Inside Plug-ins and Fragments packaged as JARs</li>- <li>Sub-directories of the directory named "src" of certain Plug-ins</li>- <li>Feature directories</li>+ <li>The top-level (root) directory</li>+ <li>Plug-in and Fragment directories</li>+ <li>Inside Plug-ins and Fragments packaged as JARs</li>+ <li>Sub-directories of the directory named "src" of certain Plug-ins</li>+ <li>Feature directories</li></ul>-+<p>Note: if a Feature made available by the Eclipse Foundation isinstalled using the Eclipse Update Manager, you must agree to a license("Feature Update License") during the@@ -84,12 +84,12 @@ CONDITIONS. SOME OF THESEOTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p><ul>- <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>- <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>- <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>- <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>- <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>- <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li>+ <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>+ <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>+ <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>+ <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>+ <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>+ <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li></ul><p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS ANDdiff --git a/solr/licenses/http2-server-NOTICE.txt b/solr/licenses/http2-server-NOTICE.txtindex b6817e12bc3..e9461a8e86e 100644--- a/solr/licenses/http2-server-NOTICE.txt+++ b/solr/licenses/http2-server-NOTICE.txt@@ -31,18 +31,18 @@ repository ("Repository") in CVS modules ("Modules") and made availableas downloadable archives ("Downloads").</p><ul>- <li>Content may be structured and packaged into modules to+ <li>Content may be structured and packaged into modules tofacilitate delivering, extending, and upgrading the Content. Typicalmodules may include plug-ins ("Plug-ins"), plug-in fragments("Fragments"), and features ("Features").</li>- <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li>- <li>A+ <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li>+ <li>AFeature is a bundle of one or more Plug-ins and/or Fragments andassociated material. Each Feature may be packaged as a sub-directory ina directory named "features". Within a Feature, files named"feature.xml" may contain a list of the names and version numbers ofthe Plug-ins and/or Fragments associated with that Feature.</li>- <li>Features+ <li>Featuresmay also include other Features ("Included Features"). Within aFeature, files named "feature.xml" may contain a list of the names andversion numbers of Included Features.</li>@@ -57,13 +57,13 @@ directory of a Download or Moduleincluding, but not limited to the following locations:</p><ul>- <li>The top-level (root) directory</li>- <li>Plug-in and Fragment directories</li>- <li>Inside Plug-ins and Fragments packaged as JARs</li>- <li>Sub-directories of the directory named "src" of certain Plug-ins</li>- <li>Feature directories</li>+ <li>The top-level (root) directory</li>+ <li>Plug-in and Fragment directories</li>+ <li>Inside Plug-ins and Fragments packaged as JARs</li>+ <li>Sub-directories of the directory named "src" of certain Plug-ins</li>+ <li>Feature directories</li></ul>-+<p>Note: if a Feature made available by the Eclipse Foundation isinstalled using the Eclipse Update Manager, you must agree to a license("Feature Update License") during the@@ -84,12 +84,12 @@ CONDITIONS. SOME OF THESEOTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p><ul>- <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>- <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>- <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>- <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>- <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>- <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li>+ <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>+ <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>+ <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>+ <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>+ <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>+ <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li></ul><p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS ANDdiff --git a/solr/licenses/jetty-NOTICE.txt b/solr/licenses/jetty-NOTICE.txtindex b6817e12bc3..e9461a8e86e 100644--- a/solr/licenses/jetty-NOTICE.txt+++ b/solr/licenses/jetty-NOTICE.txt@@ -31,18 +31,18 @@ repository ("Repository") in CVS modules ("Modules") and made availableas downloadable archives ("Downloads").</p><ul>- <li>Content may be structured and packaged into modules to+ <li>Content may be structured and packaged into modules tofacilitate delivering, extending, and upgrading the Content. Typicalmodules may include plug-ins ("Plug-ins"), plug-in fragments("Fragments"), and features ("Features").</li>- <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li>- <li>A+ <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li>+ <li>AFeature is a bundle of one or more Plug-ins and/or Fragments andassociated material. Each Feature may be packaged as a sub-directory ina directory named "features". Within a Feature, files named"feature.xml" may contain a list of the names and version numbers ofthe Plug-ins and/or Fragments associated with that Feature.</li>- <li>Features+ <li>Featuresmay also include other Features ("Included Features"). Within aFeature, files named "feature.xml" may contain a list of the names andversion numbers of Included Features.</li>@@ -57,13 +57,13 @@ directory of a Download or Moduleincluding, but not limited to the following locations:</p><ul>- <li>The top-level (root) directory</li>- <li>Plug-in and Fragment directories</li>- <li>Inside Plug-ins and Fragments packaged as JARs</li>- <li>Sub-directories of the directory named "src" of certain Plug-ins</li>- <li>Feature directories</li>+ <li>The top-level (root) directory</li>+ <li>Plug-in and Fragment directories</li>+ <li>Inside Plug-ins and Fragments packaged as JARs</li>+ <li>Sub-directories of the directory named "src" of certain Plug-ins</li>+ <li>Feature directories</li></ul>-+<p>Note: if a Feature made available by the Eclipse Foundation isinstalled using the Eclipse Update Manager, you must agree to a license("Feature Update License") during the@@ -84,12 +84,12 @@ CONDITIONS. SOME OF THESEOTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p><ul>- <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>- <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>- <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>- <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>- <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>- <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li>+ <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>+ <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>+ <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>+ <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>+ <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>+ <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li></ul><p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS ANDdiff --git a/solr/licenses/junit-LICENSE-CPL.txt b/solr/licenses/junit-LICENSE-CPL.txtindex e3f47c46371..4efdc7b204b 100644--- a/solr/licenses/junit-LICENSE-CPL.txt+++ b/solr/licenses/junit-LICENSE-CPL.txt@@ -10,8 +10,8 @@ THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS COMMON PUBLIC LICENa) in the case of the initial Contributor, the initial code and documentation distributed under this Agreement, andb) in the case of each subsequent Contributor:-i) changes to the Program, and-ii) additions to the Program;+i) changes to the Program, and+ii) additions to the Program;where such changes and/or additions to the Program originate from and are distributed by that particular Contributor. A Contribution 'originates' from a Contributor if it was added to the Program by such Contributor itself or anyone acting on such Contributor's behalf. Contributions do not include additions to the Program which: (i) are separate modules of software distributed in conjunction with the Program under their own license agreement, and (ii) are not derivative works of the Program."Contributor" means any person or entity that distributes the Program.@@ -28,24 +28,24 @@ where such changes and/or additions to the Program originate from and are distri2. GRANT OF RIGHTS-a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code form.+a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code form.b) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free patent license under Licensed Patents to make, use, sell, offer to sell, import and otherwise transfer the Contribution of such Contributor, if any, in source code and object code form. This patent license shall apply to the combination of the Contribution and the Program if, at the time the Contribution is added by the Contributor, such addition of the Contribution causes such combination to be covered by the Licensed Patents. The patent license shall not apply to any other combinations which include the Contribution. No hardware per se is licensed hereunder.-c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the Program, it is Recipient's responsibility to acquire that license before distributing the Program.-d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to grant the copyright license set forth in this Agreement.+c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the Program, it is Recipient's responsibility to acquire that license before distributing the Program.+d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to grant the copyright license set forth in this Agreement.3. REQUIREMENTSA Contributor may choose to distribute the Program in object code form under its own license agreement, provided that:-a) it complies with the terms and conditions of this Agreement; and-b) its license agreement:-i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and fitness for a particular purpose;+a) it complies with the terms and conditions of this Agreement; and+b) its license agreement:+i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and fitness for a particular purpose;ii) effectively excludes on behalf of all Contributors all liability for damages, including direct, indirect, special, incidental and consequential damages, such as lost profits;-iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any other party; and-iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it in a reasonable manner on or through a medium customarily used for software exchange.+iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any other party; and+iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it in a reasonable manner on or through a medium customarily used for software exchange.When the Program is made available in source code form:-a) it must be made available under this Agreement; and-b) a copy of this Agreement must be included with each copy of the Program.+a) it must be made available under this Agreement; and+b) a copy of this Agreement must be included with each copy of the Program.Contributors may not remove or alter any copyright notices contained within the Program.diff --git a/solr/licenses/poi-LICENSE-ASL.txt b/solr/licenses/poi-LICENSE-ASL.txtindex d179489f478..09d38da72d2 100644--- a/solr/licenses/poi-LICENSE-ASL.txt+++ b/solr/licenses/poi-LICENSE-ASL.txt@@ -514,24 +514,24 @@ SLF4J library (slf4j-api-*.jar)inbot-utils (https://github.com/Inbot/inbot-utils)- The MIT License (MIT)-- Copyright (c) 2015 Inbot-- Permission is hereby granted, free of charge, to any person obtaining a copy- of this software and associated documentation files (the "Software"), to deal- in the Software without restriction, including without limitation the rights- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell- copies of the Software, and to permit persons to whom the Software is- furnished to do so, subject to the following conditions:-- The above copyright notice and this permission notice shall be included in all- copies or substantial portions of the Software.-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE- SOFTWARE.+ The MIT License (MIT)++ Copyright (c) 2015 Inbot++ Permission is hereby granted, free of charge, to any person obtaining a copy+ of this software and associated documentation files (the "Software"), to deal+ in the Software without restriction, including without limitation the rights+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+ copies of the Software, and to permit persons to whom the Software is+ furnished to do so, subject to the following conditions:++ The above copyright notice and this permission notice shall be included in all+ copies or substantial portions of the Software.++ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+ SOFTWARE.diff --git a/solr/licenses/poi-ooxml-LICENSE-ASL.txt b/solr/licenses/poi-ooxml-LICENSE-ASL.txtindex d179489f478..09d38da72d2 100644--- a/solr/licenses/poi-ooxml-LICENSE-ASL.txt+++ b/solr/licenses/poi-ooxml-LICENSE-ASL.txt@@ -514,24 +514,24 @@ SLF4J library (slf4j-api-*.jar)inbot-utils (https://github.com/Inbot/inbot-utils)- The MIT License (MIT)-- Copyright (c) 2015 Inbot-- Permission is hereby granted, free of charge, to any person obtaining a copy- of this software and associated documentation files (the "Software"), to deal- in the Software without restriction, including without limitation the rights- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell- copies of the Software, and to permit persons to whom the Software is- furnished to do so, subject to the following conditions:-- The above copyright notice and this permission notice shall be included in all- copies or substantial portions of the Software.-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE- SOFTWARE.+ The MIT License (MIT)++ Copyright (c) 2015 Inbot++ Permission is hereby granted, free of charge, to any person obtaining a copy+ of this software and associated documentation files (the "Software"), to deal+ in the Software without restriction, including without limitation the rights+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+ copies of the Software, and to permit persons to whom the Software is+ furnished to do so, subject to the following conditions:++ The above copyright notice and this permission notice shall be included in all+ copies or substantial portions of the Software.++ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+ SOFTWARE.diff --git a/solr/licenses/poi-ooxml-schemas-LICENSE-ASL.txt b/solr/licenses/poi-ooxml-schemas-LICENSE-ASL.txtindex d179489f478..09d38da72d2 100644--- a/solr/licenses/poi-ooxml-schemas-LICENSE-ASL.txt+++ b/solr/licenses/poi-ooxml-schemas-LICENSE-ASL.txt@@ -514,24 +514,24 @@ SLF4J library (slf4j-api-*.jar)inbot-utils (https://github.com/Inbot/inbot-utils)- The MIT License (MIT)-- Copyright (c) 2015 Inbot-- Permission is hereby granted, free of charge, to any person obtaining a copy- of this software and associated documentation files (the "Software"), to deal- in the Software without restriction, including without limitation the rights- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell- copies of the Software, and to permit persons to whom the Software is- furnished to do so, subject to the following conditions:-- The above copyright notice and this permission notice shall be included in all- copies or substantial portions of the Software.-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE- SOFTWARE.+ The MIT License (MIT)++ Copyright (c) 2015 Inbot++ Permission is hereby granted, free of charge, to any person obtaining a copy+ of this software and associated documentation files (the "Software"), to deal+ in the Software without restriction, including without limitation the rights+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+ copies of the Software, and to permit persons to whom the Software is+ furnished to do so, subject to the following conditions:++ The above copyright notice and this permission notice shall be included in all+ copies or substantial portions of the Software.++ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+ SOFTWARE.diff --git a/solr/licenses/poi-scratchpad-LICENSE-ASL.txt b/solr/licenses/poi-scratchpad-LICENSE-ASL.txtindex d179489f478..09d38da72d2 100644--- a/solr/licenses/poi-scratchpad-LICENSE-ASL.txt+++ b/solr/licenses/poi-scratchpad-LICENSE-ASL.txt@@ -514,24 +514,24 @@ SLF4J library (slf4j-api-*.jar)inbot-utils (https://github.com/Inbot/inbot-utils)- The MIT License (MIT)-- Copyright (c) 2015 Inbot-- Permission is hereby granted, free of charge, to any person obtaining a copy- of this software and associated documentation files (the "Software"), to deal- in the Software without restriction, including without limitation the rights- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell- copies of the Software, and to permit persons to whom the Software is- furnished to do so, subject to the following conditions:-- The above copyright notice and this permission notice shall be included in all- copies or substantial portions of the Software.-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE- SOFTWARE.+ The MIT License (MIT)++ Copyright (c) 2015 Inbot++ Permission is hereby granted, free of charge, to any person obtaining a copy+ of this software and associated documentation files (the "Software"), to deal+ in the Software without restriction, including without limitation the rights+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+ copies of the Software, and to permit persons to whom the Software is+ furnished to do so, subject to the following conditions:++ The above copyright notice and this permission notice shall be included in all+ copies or substantial portions of the Software.++ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+ SOFTWARE.diff --git a/solr/server/etc/jetty.xml b/solr/server/etc/jetty.xmlindex 34940b535fa..1f6de775a49 100644--- a/solr/server/etc/jetty.xml+++ b/solr/server/etc/jetty.xml@@ -136,12 +136,12 @@</New></Set></New>-- <!-- =========================================================== -->- <!-- Set handler Collection Structure -->- <!-- =========================================================== -->- <Set name="handler">- <Ref id="RewriteHandler"/>++ <!-- =========================================================== -->+ <!-- Set handler Collection Structure -->+ <!-- =========================================================== -->+ <Set name="handler">+ <Ref id="RewriteHandler"/></Set><!-- =========================================================== -->diff --git a/solr/solr-ref-guide/tools/CustomizedAsciidoctorAntTask.java b/solr/solr-ref-guide/tools/CustomizedAsciidoctorAntTask.javaindex 346d8ab0aa2..5c1d700676d 100644--- a/solr/solr-ref-guide/tools/CustomizedAsciidoctorAntTask.java+++ b/solr/solr-ref-guide/tools/CustomizedAsciidoctorAntTask.java@@ -22,6 +22,7 @@ import org.asciidoctor.ant.AsciidoctorAntTask;* in order to be able to wrap in a macro with defaults*/public class CustomizedAsciidoctorAntTask extends AsciidoctorAntTask {+ @SuppressWarnings("UnusedDeclaration")public void setSourceDocumentName(String sourceDocumentName) {if ("".equals(sourceDocumentName)) {sourceDocumentName = null;diff --git a/solr/solrj/src/java/org/apache/solr/client/solrj/cloud/autoscaling/AutoScalingConfig.java b/solr/solrj/src/java/org/apache/solr/client/solrj/cloud/autoscaling/AutoScalingConfig.javaindex b298a8362a6..366b891e1b3 100644--- a/solr/solrj/src/java/org/apache/solr/client/solrj/cloud/autoscaling/AutoScalingConfig.java+++ b/solr/solrj/src/java/org/apache/solr/client/solrj/cloud/autoscaling/AutoScalingConfig.java@@ -42,7 +42,6 @@ import static java.util.stream.Collectors.toList;* Bean representation of <code>autoscaling.json</code>, which parses data* lazily.*/-@SuppressWarnings("unchecked")public class AutoScalingConfig implements MapWriter {private static final Logger log = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());@@ -570,7 +569,6 @@ public class AutoScalingConfig implements MapWriter {return getList(key, properties, null);}- @SuppressWarnings("rawtypes")private static List<Object> getList(String key, Map<String, Object> properties, List<Object> defaultList) {if (defaultList == null) {defaultList = Collections.emptyList();diff --git a/solr/solrj/src/java/org/apache/solr/client/solrj/cloud/autoscaling/Clause.java b/solr/solrj/src/java/org/apache/solr/client/solrj/cloud/autoscaling/Clause.javaindex 290661f26cb..f12ecce6a8c 100644--- a/solr/solrj/src/java/org/apache/solr/client/solrj/cloud/autoscaling/Clause.java+++ b/solr/solrj/src/java/org/apache/solr/client/solrj/cloud/autoscaling/Clause.java@@ -56,7 +56,6 @@ import static org.apache.solr.common.util.Utils.toJSONString;/*** Represents a set of conditions in the policy*/-@SuppressWarnings({"rawtypes", "unchecked"})public class Clause implements MapWriter, Comparable<Clause> {public static final String NODESET = "nodeset";static final Set<String> IGNORE_TAGS = new HashSet<>(Arrays.asList(REPLICA, COLLECTION, SHARD, "strict", "type", "put", NODESET));diff --git a/solr/solrj/src/java/org/apache/solr/client/solrj/cloud/autoscaling/Policy.java b/solr/solrj/src/java/org/apache/solr/client/solrj/cloud/autoscaling/Policy.javaindex e9b814855cd..afe04b51ba7 100644--- a/solr/solrj/src/java/org/apache/solr/client/solrj/cloud/autoscaling/Policy.java+++ b/solr/solrj/src/java/org/apache/solr/client/solrj/cloud/autoscaling/Policy.java@@ -79,7 +79,6 @@ public class Policy implements MapWriter {public static final String CLUSTER_POLICY = "cluster-policy";public static final String CLUSTER_PREFERENCES = "cluster-preferences";public static final Set<String> GLOBAL_ONLY_TAGS = Set.of("cores", CollectionAdminParams.WITH_COLLECTION);- @SuppressWarnings("unchecked")public static final List<Preference> DEFAULT_PREFERENCES = Collections.unmodifiableList(Arrays.asList(// NOTE - if you change this, make sure to update the solrcloud-autoscaling-overview.adoc which@@ -278,7 +277,6 @@ public class Policy implements MapWriter {return newPolicies;}- @SuppressWarnings("rawtypes")static void setApproxValuesAndSortNodes(List<Preference> clusterPreferences, List<Row> matrix) {List<Row> matrixCopy = new ArrayList<>(matrix);List<Row> deadNodes = null;@@ -530,7 +528,6 @@ public class Policy implements MapWriter {}- @SuppressWarnings("unchecked")Session(SolrCloudManager cloudManager, Transaction transaction) {this.transaction = transaction;ClusterState state = null;diff --git a/solr/solrj/src/java/org/apache/solr/client/solrj/cloud/autoscaling/Variable.java b/solr/solrj/src/java/org/apache/solr/client/solrj/cloud/autoscaling/Variable.javaindex 84d5d656aea..22fd7a55ef0 100644--- a/solr/solrj/src/java/org/apache/solr/client/solrj/cloud/autoscaling/Variable.java+++ b/solr/solrj/src/java/org/apache/solr/client/solrj/cloud/autoscaling/Variable.java@@ -237,7 +237,6 @@ public interface Variable {DISKTYPE;public final String tagName;- @SuppressWarnings("rawtypes")public final Class type;public Meta meta;@@ -253,7 +252,6 @@ public interface Variable {final Variable impl;- @SuppressWarnings({"unchecked", "rawtypes"})Type() {try {meta = Type.class.getField(name()).getAnnotation(Meta.class);@@ -377,7 +375,6 @@ public interface Variable {@interface Meta {String name();- @SuppressWarnings("rawtypes")Class type();String[] associatedPerNodeValue() default NULL;@@ -402,7 +399,6 @@ public interface Variable {String metricsKey() default NULL;- @SuppressWarnings("rawtypes")Class implementation() default void.class;ComputedType[] computedValues() default ComputedType.NULL;diff --git a/solr/solrj/src/java/org/apache/solr/client/solrj/impl/BaseCloudSolrClient.java b/solr/solrj/src/java/org/apache/solr/client/solrj/impl/BaseCloudSolrClient.javaindex e0ca122ba32..0461e67f4fa 100644--- a/solr/solrj/src/java/org/apache/solr/client/solrj/impl/BaseCloudSolrClient.java+++ b/solr/solrj/src/java/org/apache/solr/client/solrj/impl/BaseCloudSolrClient.java@@ -89,7 +89,6 @@ import org.slf4j.MDC;import static org.apache.solr.common.params.CommonParams.ADMIN_PATHS;import static org.apache.solr.common.params.CommonParams.ID;-@SuppressWarnings({"rawtypes", "unchecked"})public abstract class BaseCloudSolrClient extends SolrClient {private static final Logger log = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());@@ -1223,6 +1222,7 @@ public abstract class BaseCloudSolrClient extends SolrClient {* all shards involved in processing an update request, typically useful* for gauging the replication factor of a batch.*/+ @SuppressWarnings("rawtypes")public int getMinAchievedReplicationFactor(String collection, NamedList resp) {// it's probably already on the top-level header set by condenseNamedList header = (NamedList)resp.get("responseHeader");@@ -1245,6 +1245,7 @@ public abstract class BaseCloudSolrClient extends SolrClient {* the replication factor that was achieved in each shard involved in the request.* For single doc updates, there will be only one shard in the return value.*/+ @SuppressWarnings("rawtypes")public Map<String,Integer> getShardReplicationFactor(String collection, NamedList resp) {connect();diff --git a/solr/solrj/src/java/org/apache/solr/client/solrj/impl/BaseHttpClusterStateProvider.java b/solr/solrj/src/java/org/apache/solr/client/solrj/impl/BaseHttpClusterStateProvider.javaindex 9b088f57591..6c6eb250505 100644--- a/solr/solrj/src/java/org/apache/solr/client/solrj/impl/BaseHttpClusterStateProvider.java+++ b/solr/solrj/src/java/org/apache/solr/client/solrj/impl/BaseHttpClusterStateProvider.java@@ -254,7 +254,6 @@ public abstract class BaseHttpClusterStateProvider implements ClusterStateProvid}@Override- @SuppressWarnings("deprecation")public ClusterState getClusterState() throws IOException {for (String nodeName: liveNodes) {String baseUrl = Utils.getBaseUrlForNodeName(nodeName, urlScheme);@@ -276,7 +275,6 @@ public abstract class BaseHttpClusterStateProvider implements ClusterStateProvid}@Override- @SuppressWarnings("deprecation")public Map<String, Object> getClusterProperties() {for (String nodeName : liveNodes) {String baseUrl = Utils.getBaseUrlForNodeName(nodeName, urlScheme);diff --git a/solr/solrj/src/java/org/apache/solr/client/solrj/impl/BaseHttpSolrClient.java b/solr/solrj/src/java/org/apache/solr/client/solrj/impl/BaseHttpSolrClient.javaindex b0c645b3d1e..dceb13c20e5 100644--- a/solr/solrj/src/java/org/apache/solr/client/solrj/impl/BaseHttpSolrClient.java+++ b/solr/solrj/src/java/org/apache/solr/client/solrj/impl/BaseHttpSolrClient.java@@ -48,7 +48,6 @@ public abstract class BaseHttpSolrClient extends SolrClient {* This should be thrown when a server has an error in executing the request and* it sends a proper payload back to the client*/- @SuppressWarnings("serial")public static class RemoteExecutionException extends HttpSolrClient.RemoteSolrException {private NamedList meta;@@ -58,7 +57,6 @@ public abstract class BaseHttpSolrClient extends SolrClient {}- @SuppressWarnings("deprecation")public static HttpSolrClient.RemoteExecutionException create(String host, NamedList errResponse) {Object errObj = errResponse.get("error");if (errObj != null) {diff --git a/solr/solrj/src/java/org/apache/solr/client/solrj/impl/ConcurrentUpdateSolrClient.java b/solr/solrj/src/java/org/apache/solr/client/solrj/impl/ConcurrentUpdateSolrClient.javaindex 6af0d33d0b1..e19d2783e0e 100644--- a/solr/solrj/src/java/org/apache/solr/client/solrj/impl/ConcurrentUpdateSolrClient.java+++ b/solr/solrj/src/java/org/apache/solr/client/solrj/impl/ConcurrentUpdateSolrClient.java@@ -218,7 +218,6 @@ public class ConcurrentUpdateSolrClient extends SolrClient {// Pull from the queue multiple times and streams over a single connection.// Exits on exception, interruption, or an empty queue to pull from.//- @SuppressWarnings({"deprecation", "unchecked"})void sendUpdateStream() throws Exception {while (!queue.isEmpty()) {@@ -357,7 +356,7 @@ public class ConcurrentUpdateSolrClient extends SolrClient {msg.append(response.getStatusLine().getReasonPhrase());msg.append("\n\n\n\n");msg.append("request: ").append(method.getURI());-+SolrException solrExc;NamedList<String> metadata = null;// parse out the metadata from the SolrException@@ -474,7 +473,6 @@ public class ConcurrentUpdateSolrClient extends SolrClient {}}- @SuppressWarnings("rawtypes")@Overridepublic NamedList<Object> request(final SolrRequest request, String collection)throws SolrServerException, IOException {diff --git a/solr/solrj/src/java/org/apache/solr/client/solrj/impl/HttpSolrClient.java b/solr/solrj/src/java/org/apache/solr/client/solrj/impl/HttpSolrClient.javaindex 136e0c36993..c5273278d9f 100644--- a/solr/solrj/src/java/org/apache/solr/client/solrj/impl/HttpSolrClient.java+++ b/solr/solrj/src/java/org/apache/solr/client/solrj/impl/HttpSolrClient.java@@ -93,7 +93,6 @@ import static org.apache.solr.common.util.Utils.getObjectByPath;/*** A SolrClient implementation that talks directly to a Solr server via HTTP*/-@SuppressWarnings("unchecked")public class HttpSolrClient extends BaseHttpSolrClient {private static final String UTF_8 = StandardCharsets.UTF_8.name();diff --git a/solr/solrj/src/java/org/apache/solr/client/solrj/request/UpdateRequest.java b/solr/solrj/src/java/org/apache/solr/client/solrj/request/UpdateRequest.javaindex 982dff48d3b..902223e30d1 100644--- a/solr/solrj/src/java/org/apache/solr/client/solrj/request/UpdateRequest.java+++ b/solr/solrj/src/java/org/apache/solr/client/solrj/request/UpdateRequest.java@@ -60,7 +60,6 @@ public class UpdateRequest extends AbstractUpdateRequest {* @deprecated Solr now always includes in the response the {@link #REPFACT}, this parameter* doesn't need to be explicitly set*/- @Deprecatedpublic static final String MIN_REPFACT = "min_rf";public static final String VER = "ver";public static final String OVERWRITE = "ow";diff --git a/solr/solrj/src/java/org/apache/solr/common/IteratorWriter.java b/solr/solrj/src/java/org/apache/solr/common/IteratorWriter.javaindex 1a8fc1ca275..ec11c786d02 100644--- a/solr/solrj/src/java/org/apache/solr/common/IteratorWriter.java+++ b/solr/solrj/src/java/org/apache/solr/common/IteratorWriter.java@@ -78,7 +78,6 @@ public interface IteratorWriter {try {writeIter(new ItemWriter() {@Override- @SuppressWarnings("unchecked")public ItemWriter add(Object o) throws IOException {if (o instanceof MapWriter) o = ((MapWriter) o).toMap(new LinkedHashMap<>());if (o instanceof IteratorWriter) o = ((IteratorWriter) o).toList(new ArrayList<>());diff --git a/solr/solrj/src/java/org/apache/solr/common/MapWriter.java b/solr/solrj/src/java/org/apache/solr/common/MapWriter.javaindex 07b215e9500..926cf4c360d 100644--- a/solr/solrj/src/java/org/apache/solr/common/MapWriter.java+++ b/solr/solrj/src/java/org/apache/solr/common/MapWriter.java@@ -40,7 +40,6 @@ public interface MapWriter extends MapSerializable , NavigableObject {}@Override- @SuppressWarnings("unchecked")default Map toMap(Map<String, Object> map) {try {writeMap(new EntryWriter() {diff --git a/solr/solrj/src/java/org/apache/solr/common/SolrDocument.java b/solr/solrj/src/java/org/apache/solr/common/SolrDocument.javaindex 4720f796311..fd56d9dc985 100644--- a/solr/solrj/src/java/org/apache/solr/common/SolrDocument.java+++ b/solr/solrj/src/java/org/apache/solr/common/SolrDocument.java@@ -408,8 +408,6 @@ public class SolrDocument extends SolrDocumentBase<Object, SolrDocument> impleme}@Override-- @Deprecatedpublic int getChildDocumentCount() {if (_childDocuments == null) return 0;return _childDocuments.size();diff --git a/solr/solrj/src/java/org/apache/solr/common/SolrException.java b/solr/solrj/src/java/org/apache/solr/common/SolrException.javaindex f5c8423484b..673bae7212a 100644--- a/solr/solrj/src/java/org/apache/solr/common/SolrException.java+++ b/solr/solrj/src/java/org/apache/solr/common/SolrException.java@@ -29,7 +29,6 @@ import org.slf4j.MDC;/****/-@SuppressWarnings("unchecked")public class SolrException extends RuntimeException {public static final String ROOT_ERROR_CLASS = "root-error-class";diff --git a/solr/solrj/src/java/org/apache/solr/common/SolrInputDocument.java b/solr/solrj/src/java/org/apache/solr/common/SolrInputDocument.javaindex fa8858436aa..860f3d5fea2 100644--- a/solr/solrj/src/java/org/apache/solr/common/SolrInputDocument.java+++ b/solr/solrj/src/java/org/apache/solr/common/SolrInputDocument.java@@ -289,7 +289,6 @@ public class SolrInputDocument extends SolrDocumentBase<SolrInputField, SolrInpu}@Override- @Deprecatedpublic int getChildDocumentCount() {return hasChildDocuments() ? _childDocuments.size(): 0;}diff --git a/solr/solrj/src/java/org/apache/solr/common/SolrInputField.java b/solr/solrj/src/java/org/apache/solr/common/SolrInputField.javaindex 4eb30f17c17..8b4add6523b 100644--- a/solr/solrj/src/java/org/apache/solr/common/SolrInputField.java+++ b/solr/solrj/src/java/org/apache/solr/common/SolrInputField.java@@ -27,7 +27,6 @@ import static org.apache.solr.common.util.ByteArrayUtf8CharSequence.convertCharS** @since solr 1.3*/-@SuppressWarnings({"unchecked", "rawtypes"})public class SolrInputField implements Iterable<Object>, Serializable{String name;@@ -64,6 +63,7 @@ public class SolrInputField implements Iterable<Object>, Serializable* Add values to a field. If the added value is a collection, each value* will be added individually.*/+ @SuppressWarnings("unchecked")public void addValue(Object v) {if( value == null ) {if ( v instanceof Collection ) {@@ -108,6 +108,7 @@ public class SolrInputField implements Iterable<Object>, Serializable//---------------------------------------------------------------//---------------------------------------------------------------+ @SuppressWarnings("unchecked")public Object getFirstValue() {if( value instanceof Collection ) {Collection c = (Collection<Object>)value;@@ -153,6 +154,7 @@ public class SolrInputField implements Iterable<Object>, Serializable* @return the values for this field. This will return a collection even* if the field is not multi-valued*/+ @SuppressWarnings("unchecked")public Collection<Object> getValues() {if (value instanceof Collection) {return convertCharSeq((Collection<Object>) value);@@ -212,7 +214,7 @@ public class SolrInputField implements Iterable<Object>, Serializable};}-+ @SuppressWarnings("unchecked")public Iterator<Object> getRawIterator() {if( value instanceof Collection ) {return ((Collection)value).iterator();diff --git a/solr/solrj/src/java/org/apache/solr/common/cloud/ClusterState.java b/solr/solrj/src/java/org/apache/solr/common/cloud/ClusterState.javaindex 7dcc1814b06..559203f6137 100644--- a/solr/solrj/src/java/org/apache/solr/common/cloud/ClusterState.java+++ b/solr/solrj/src/java/org/apache/solr/common/cloud/ClusterState.java@@ -233,7 +233,6 @@ public class ClusterState implements JSONWriter.Writable {* @param liveNodes list of live nodes* @return the ClusterState*/- @SuppressWarnings("unchecked")public static ClusterState load(Integer version, byte[] bytes, Set<String> liveNodes, String znode) {// System.out.println("######## ClusterState.load:" + (bytes==null ? null : new String(bytes)));if (bytes == null || bytes.length == 0) {@@ -243,7 +242,6 @@ public class ClusterState implements JSONWriter.Writable {return load(version, stateMap, liveNodes, znode);}- @SuppressWarnings("unchecked")public static ClusterState load(Integer version, Map<String, Object> stateMap, Set<String> liveNodes, String znode) {Map<String,CollectionRef> collections = new LinkedHashMap<>(stateMap.size());for (Entry<String, Object> entry : stateMap.entrySet()) {@@ -256,7 +254,6 @@ public class ClusterState implements JSONWriter.Writable {}// TODO move to static DocCollection.loadFromMap- @SuppressWarnings("unchecked")private static DocCollection collectionFromObjects(String name, Map<String, Object> objs, Integer version, String znode) {Map<String,Object> props;Map<String,Slice> slices;diff --git a/solr/solrj/src/java/org/apache/solr/common/cloud/CompositeIdRouter.java b/solr/solrj/src/java/org/apache/solr/common/cloud/CompositeIdRouter.javaindex c52fd61b90e..d700464c690 100644--- a/solr/solrj/src/java/org/apache/solr/common/cloud/CompositeIdRouter.java+++ b/solr/solrj/src/java/org/apache/solr/common/cloud/CompositeIdRouter.java@@ -149,7 +149,7 @@ public class CompositeIdRouter extends HashBasedRouter {int max = range.max;assert max >= min;- if (partitions == 0) return Collections.emptyList();+ if (partitions == 0) return Collections.EMPTY_LIST;long rangeSize = (long) max - (long) min;long rangeStep = Math.max(1, rangeSize / partitions);diff --git a/solr/solrj/src/java/org/apache/solr/common/cloud/Slice.java b/solr/solrj/src/java/org/apache/solr/common/cloud/Slice.javaindex 9870c0fd06f..2acbd00b15e 100644--- a/solr/solrj/src/java/org/apache/solr/common/cloud/Slice.java+++ b/solr/solrj/src/java/org/apache/solr/common/cloud/Slice.java@@ -36,7 +36,6 @@ import static org.apache.solr.common.util.Utils.toJSONString;/*** A Slice contains immutable information about a logical shard (all replicas that share the same shard id).*/-@SuppressWarnings("unchecked")public class Slice extends ZkNodeProps implements Iterable<Replica> {/** Loads multiple slices into a Map from a generic Map that probably came from deserialized JSON. */diff --git a/solr/solrj/src/java/org/apache/solr/common/cloud/ZkStateReader.java b/solr/solrj/src/java/org/apache/solr/common/cloud/ZkStateReader.javaindex cac90705fc4..7185f4e7c7d 100644--- a/solr/solrj/src/java/org/apache/solr/common/cloud/ZkStateReader.java+++ b/solr/solrj/src/java/org/apache/solr/common/cloud/ZkStateReader.java@@ -243,7 +243,6 @@ public class ZkStateReader implements SolrCloseable {* @return current configuration from <code>autoscaling.json</code>. NOTE:* this data is retrieved from ZK on each call.*/- @SuppressWarnings("unchecked")public AutoScalingConfig getAutoScalingConfig(Watcher watcher) throws KeeperException, InterruptedException {Stat stat = new Stat();diff --git a/solr/solrj/src/java/org/apache/solr/common/params/CommonParams.java b/solr/solrj/src/java/org/apache/solr/common/params/CommonParams.javaindex ecfcee557bd..ca01ce4e4a9 100644--- a/solr/solrj/src/java/org/apache/solr/common/params/CommonParams.java+++ b/solr/solrj/src/java/org/apache/solr/common/params/CommonParams.java@@ -273,7 +273,6 @@ public interface CommonParams {* When querying a node, prefer local node's cores for distributed queries.* @deprecated Use {@code ShardParams.SHARDS_PREFERENCE}*/- @DeprecatedString PREFER_LOCAL_SHARDS = "preferLocalShards";String JAVABIN = "javabin";diff --git a/solr/solrj/src/java/org/apache/solr/common/util/ByteArrayUtf8CharSequence.java b/solr/solrj/src/java/org/apache/solr/common/util/ByteArrayUtf8CharSequence.javaindex d0c9f98a41a..7a4abe2c303 100644--- a/solr/solrj/src/java/org/apache/solr/common/util/ByteArrayUtf8CharSequence.java+++ b/solr/solrj/src/java/org/apache/solr/common/util/ByteArrayUtf8CharSequence.java@@ -180,7 +180,6 @@ public class ByteArrayUtf8CharSequence implements Utf8CharSequence {return new ByteArrayUtf8CharSequence(bytes, 0, length, utf16, hashCode);}- @SuppressWarnings("unchecked")public static Map.Entry convertCharSeq(Map.Entry e) {if (e.getKey() instanceof Utf8CharSequence || e.getValue() instanceof Utf8CharSequence) {return new AbstractMap.SimpleEntry(convertCharSeq(e.getKey()), convertCharSeq(e.getValue()));@@ -189,7 +188,6 @@ public class ByteArrayUtf8CharSequence implements Utf8CharSequence {}- @SuppressWarnings("unchecked")public static Collection convertCharSeq(Collection vals) {if (vals == null) return vals;boolean needsCopy = false;diff --git a/solr/solrj/src/java/org/apache/solr/common/util/JavaBinCodec.java b/solr/solrj/src/java/org/apache/solr/common/util/JavaBinCodec.javaindex 28e088ad806..1096f67553a 100644--- a/solr/solrj/src/java/org/apache/solr/common/util/JavaBinCodec.java+++ b/solr/solrj/src/java/org/apache/solr/common/util/JavaBinCodec.java@@ -72,7 +72,6 @@ import static org.apache.solr.common.util.ByteArrayUtf8CharSequence.convertCharS* <p>* NOTE -- {@link JavaBinCodec} instances cannot be reused for more than one marshall or unmarshall operation.*/-@SuppressWarnings("unchecked")public class JavaBinCodec implements PushWriter {private static final Logger log = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());diff --git a/solr/solrj/src/java/org/apache/solr/common/util/JsonRecordReader.java b/solr/solrj/src/java/org/apache/solr/common/util/JsonRecordReader.javaindex efbb0bd9e1b..f66c88e4118 100644--- a/solr/solrj/src/java/org/apache/solr/common/util/JsonRecordReader.java+++ b/solr/solrj/src/java/org/apache/solr/common/util/JsonRecordReader.java@@ -28,7 +28,7 @@ import static org.noggit.JSONParser.*;/*** A Streaming parser for json to emit one record at a time.*/-@SuppressWarnings({"unchecked", "rawtypes"})+public class JsonRecordReader {public static final String DELIM = ".";diff --git a/solr/solrj/src/java/org/apache/solr/common/util/JsonSchemaValidator.java b/solr/solrj/src/java/org/apache/solr/common/util/JsonSchemaValidator.javaindex 1952bcad0f5..b1fcc914342 100644--- a/solr/solrj/src/java/org/apache/solr/common/util/JsonSchemaValidator.java+++ b/solr/solrj/src/java/org/apache/solr/common/util/JsonSchemaValidator.java@@ -34,7 +34,6 @@ import java.util.function.Function;* It validates most aspects of json schema but it is NOT A FULLY COMPLIANT JSON schema parser or validator.* This validator borrow some design's idea from https://github.com/networknt/json-schema-validator*/-@SuppressWarnings("unchecked")public class JsonSchemaValidator {private List<Validator> validators;diff --git a/solr/solrj/src/java/org/apache/solr/common/util/JsonTextWriter.java b/solr/solrj/src/java/org/apache/solr/common/util/JsonTextWriter.javaindex f9d1476c9aa..ed8c79776f0 100644--- a/solr/solrj/src/java/org/apache/solr/common/util/JsonTextWriter.java+++ b/solr/solrj/src/java/org/apache/solr/common/util/JsonTextWriter.java@@ -232,7 +232,7 @@ public interface JsonTextWriter extends TextWriter {writeStr(name, val, false);}- @SuppressWarnings("unchecked")+default void writeMap(String name, Map val, boolean excludeOuter, boolean isFirstVal) throws IOException {if (!excludeOuter) {writeMapOpener(val.size());diff --git a/solr/solrj/src/java/org/apache/solr/common/util/NamedList.java b/solr/solrj/src/java/org/apache/solr/common/util/NamedList.javaindex 4e2f54dc5e9..3113ef95337 100644--- a/solr/solrj/src/java/org/apache/solr/common/util/NamedList.java+++ b/solr/solrj/src/java/org/apache/solr/common/util/NamedList.java@@ -61,7 +61,6 @@ import org.apache.solr.common.params.SolrParams;* </p>**/-@SuppressWarnings("unchecked")public class NamedList<T> implements Cloneable, Serializable, Iterable<Map.Entry<String,T>> , MapWriter {private static final long serialVersionUID = 1957981902839867821L;diff --git a/solr/solrj/src/java/org/apache/solr/common/util/Pair.java b/solr/solrj/src/java/org/apache/solr/common/util/Pair.javaindex 1a25eb291fd..74f5b2d6ff7 100644--- a/solr/solrj/src/java/org/apache/solr/common/util/Pair.java+++ b/solr/solrj/src/java/org/apache/solr/common/util/Pair.java@@ -66,7 +66,6 @@ public class Pair<T1, T2> implements Serializable, MapWriter {ew.put("second", second);}- @SuppressWarnings("unchecked")public static Pair parse(Map m) {return new Pair(m.get("first"), m.get("second"));}diff --git a/solr/solrj/src/java/org/apache/solr/common/util/Utils.java b/solr/solrj/src/java/org/apache/solr/common/util/Utils.javaindex ff0079d31be..7fcba6448cf 100644--- a/solr/solrj/src/java/org/apache/solr/common/util/Utils.java+++ b/solr/solrj/src/java/org/apache/solr/common/util/Utils.java@@ -88,7 +88,6 @@ import static java.util.Collections.unmodifiableList;import static java.util.Collections.unmodifiableSet;import static java.util.concurrent.TimeUnit.NANOSECONDS;-@SuppressWarnings("unchecked")public class Utils {public static final Function NEW_HASHMAP_FUN = o -> new HashMap<>();public static final Function NEW_LINKED_HASHMAP_FUN = o -> new LinkedHashMap<>();diff --git a/solr/solrj/src/java/org/apache/solr/common/util/ValidatingJsonMap.java b/solr/solrj/src/java/org/apache/solr/common/util/ValidatingJsonMap.javaindex 0a96332388e..b5375365fea 100644--- a/solr/solrj/src/java/org/apache/solr/common/util/ValidatingJsonMap.java+++ b/solr/solrj/src/java/org/apache/solr/common/util/ValidatingJsonMap.java@@ -40,7 +40,6 @@ import static java.nio.charset.StandardCharsets.UTF_8;import static java.util.Collections.unmodifiableList;import static java.util.Collections.unmodifiableSet;-@SuppressWarnings("unchecked")public class ValidatingJsonMap implements Map<String, Object>, NavigableObject {private static final String INCLUDE = "#include";diff --git a/solr/solrj/src/test/org/apache/solr/client/ref_guide_examples/JsonRequestApiTest.java b/solr/solrj/src/test/org/apache/solr/client/ref_guide_examples/JsonRequestApiTest.javaindex 86a0d8ffc99..5d78d069a31 100644--- a/solr/solrj/src/test/org/apache/solr/client/ref_guide_examples/JsonRequestApiTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/ref_guide_examples/JsonRequestApiTest.java@@ -284,7 +284,7 @@ public class JsonRequestApiTest extends SolrCloudTestCase {//tag::solrj-ipod-query-boosted-dsl-2[]final Map<String, Object> queryTopLevel = new HashMap<>();final Map<String, Object> boostProperties = new HashMap<>();- final Map<String, Object> luceneTopLevel = new HashMap<>();+ final Map<String, Object> luceneTopLevel = new HashMap();final Map<String, Object> luceneProperties = new HashMap<>();queryTopLevel.put("boost", boostProperties);boostProperties.put("b", "log(popularity)");diff --git a/solr/solrj/src/test/org/apache/solr/client/ref_guide_examples/UsingSolrJRefGuideExamplesTest.java b/solr/solrj/src/test/org/apache/solr/client/ref_guide_examples/UsingSolrJRefGuideExamplesTest.javaindex 01910d05894..c87bb87bdf6 100644--- a/solr/solrj/src/test/org/apache/solr/client/ref_guide_examples/UsingSolrJRefGuideExamplesTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/ref_guide_examples/UsingSolrJRefGuideExamplesTest.java@@ -58,7 +58,7 @@ public class UsingSolrJRefGuideExamplesTest extends SolrCloudTestCase {private static final int NUM_INDEXED_DOCUMENTS = 3;private static final int NUM_LIVE_NODES = 1;- private Queue<String> expectedLines = new ArrayDeque<>();+ private Queue<String> expectedLines = new ArrayDeque();@BeforeClasspublic static void setUpCluster() throws Exception {diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/impl/CloudHttp2SolrClientTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/impl/CloudHttp2SolrClientTest.javaindex aee735feef5..27fd172c385 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/impl/CloudHttp2SolrClientTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/impl/CloudHttp2SolrClientTest.java@@ -610,7 +610,6 @@ public class CloudHttp2SolrClientTest extends SolrCloudTestCase {}@Test- @SuppressWarnings("deprecation")public void stateVersionParamTest() throws Exception {CollectionAdminRequest.createCollection(COLLECTION, "conf", 2, 1).process(cluster.getSolrClient());cluster.waitForActiveCollection(COLLECTION, 2, 2);diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/impl/CloudSolrClientCacheTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/impl/CloudSolrClientCacheTest.javaindex 230beb70bbc..92c5c629b04 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/impl/CloudSolrClientCacheTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/impl/CloudSolrClientCacheTest.java@@ -104,7 +104,7 @@ public class CloudSolrClientCacheTest extends SolrTestCaseJ4 {}- @SuppressWarnings("deprecation")+private LBHttpSolrClient getMockLbHttpSolrClient(Map<String, Function> responses) throws Exception {LBHttpSolrClient mockLbclient = mock(LBHttpSolrClient.class);diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/impl/CloudSolrClientRetryTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/impl/CloudSolrClientRetryTest.javaindex 315337c5eb7..900ae7160f6 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/impl/CloudSolrClientRetryTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/impl/CloudSolrClientRetryTest.java@@ -40,7 +40,6 @@ public class CloudSolrClientRetryTest extends SolrCloudTestCase {}@Test- @SuppressWarnings("deprecation")public void testRetry() throws Exception {String collectionName = "testRetry";CloudSolrClient solrClient = cluster.getSolrClient();diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/impl/CloudSolrClientTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/impl/CloudSolrClientTest.javaindex 355ca985773..a505799c6e3 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/impl/CloudSolrClientTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/impl/CloudSolrClientTest.java@@ -824,7 +824,7 @@ public class CloudSolrClientTest extends SolrCloudTestCase {}}- @SuppressWarnings("deprecation")+private static void checkSingleServer(NamedList<Object> response) {final CloudSolrClient.RouteResponse rr = (CloudSolrClient.RouteResponse) response;final Map<String,LBHttpSolrClient.Req> routes = rr.getRoutes();diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AbsoluteValueEvaluatorTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AbsoluteValueEvaluatorTest.javaindex 2389c26e248..c35ed293e0d 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AbsoluteValueEvaluatorTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AbsoluteValueEvaluatorTest.java@@ -29,7 +29,7 @@ import org.apache.solr.client.solrj.io.stream.StreamContext;import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;import org.junit.Test;-import org.junit.Assert;+import junit.framework.Assert;public class AbsoluteValueEvaluatorTest extends SolrTestCase {diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AddEvaluatorTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AddEvaluatorTest.javaindex f819f56f585..ca094d59711 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AddEvaluatorTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AddEvaluatorTest.java@@ -26,7 +26,7 @@ import org.apache.solr.client.solrj.io.eval.StreamEvaluator;import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;import org.junit.Test;-import org.junit.Assert;+import junit.framework.Assert;public class AddEvaluatorTest extends SolrTestCase {diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AndEvaluatorTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AndEvaluatorTest.javaindex a766d2e7903..b28b4b6ed76 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AndEvaluatorTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AndEvaluatorTest.java@@ -26,7 +26,7 @@ import org.apache.solr.client.solrj.io.eval.StreamEvaluator;import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;import org.junit.Test;-import org.junit.Assert;+import junit.framework.Assert;public class AndEvaluatorTest extends SolrTestCase {diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AppendEvaluatorTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AppendEvaluatorTest.javaindex 119e4118f0c..f85ed3c9430 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AppendEvaluatorTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AppendEvaluatorTest.java@@ -28,7 +28,7 @@ import org.apache.solr.client.solrj.io.eval.StreamEvaluator;import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;import org.junit.Test;-import org.junit.Assert;+import junit.framework.Assert;public class AppendEvaluatorTest extends SolrTestCase {diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ArcCosineEvaluatorTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ArcCosineEvaluatorTest.javaindex 0379491c71c..66aa9f8f4c9 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ArcCosineEvaluatorTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ArcCosineEvaluatorTest.java@@ -27,7 +27,7 @@ import org.apache.solr.client.solrj.io.eval.StreamEvaluator;import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;import org.junit.Test;-import org.junit.Assert;+import junit.framework.Assert;public class ArcCosineEvaluatorTest extends SolrTestCase {diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ArcSineEvaluatorTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ArcSineEvaluatorTest.javaindex da52efa7492..e6b30908085 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ArcSineEvaluatorTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ArcSineEvaluatorTest.java@@ -27,7 +27,7 @@ import org.apache.solr.client.solrj.io.eval.StreamEvaluator;import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;import org.junit.Test;-import org.junit.Assert;+import junit.framework.Assert;public class ArcSineEvaluatorTest extends SolrTestCase {diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ArcTangentEvaluatorTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ArcTangentEvaluatorTest.javaindex 02e653f7974..15cdc0f6a64 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ArcTangentEvaluatorTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ArcTangentEvaluatorTest.java@@ -27,7 +27,7 @@ import org.apache.solr.client.solrj.io.eval.StreamEvaluator;import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;import org.junit.Test;-import org.junit.Assert;+import junit.framework.Assert;public class ArcTangentEvaluatorTest extends SolrTestCase {diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ArrayEvaluatorTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ArrayEvaluatorTest.javaindex 5cc65f33cbd..7d14d56df78 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ArrayEvaluatorTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ArrayEvaluatorTest.java@@ -29,7 +29,7 @@ import org.apache.solr.client.solrj.io.stream.StreamContext;import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;import org.junit.Test;-import org.junit.Assert;+import junit.framework.Assert;public class ArrayEvaluatorTest extends SolrTestCase {diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AscEvaluatorTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AscEvaluatorTest.javaindex 554b67a6797..8029712a4b1 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AscEvaluatorTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/AscEvaluatorTest.java@@ -28,7 +28,7 @@ import org.apache.solr.client.solrj.io.eval.StreamEvaluator;import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;import org.junit.Test;-import org.junit.Assert;+import junit.framework.Assert;public class AscEvaluatorTest extends SolrTestCase {diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/CeilingEvaluatorTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/CeilingEvaluatorTest.javaindex 28300c9b800..50e8b8ea26c 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/CeilingEvaluatorTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/CeilingEvaluatorTest.java@@ -27,7 +27,7 @@ import org.apache.solr.client.solrj.io.eval.StreamEvaluator;import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;import org.junit.Test;-import org.junit.Assert;+import junit.framework.Assert;public class CeilingEvaluatorTest extends SolrTestCase {diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ConversionEvaluatorsTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ConversionEvaluatorsTest.javaindex 19f7c5ba3c4..2194b8f2a94 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ConversionEvaluatorsTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ConversionEvaluatorsTest.java@@ -30,8 +30,8 @@ import org.apache.solr.client.solrj.io.stream.StreamContext;import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;import org.junit.Test;-import static org.junit.Assert.assertEquals;-import static org.junit.Assert.assertTrue;+import static junit.framework.Assert.assertEquals;+import static junit.framework.Assert.assertTrue;/*** Test ConversionEvaluatorsdiff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/DivideEvaluatorTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/DivideEvaluatorTest.javaindex a17dd688114..4ef136ce7d6 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/DivideEvaluatorTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/DivideEvaluatorTest.java@@ -27,7 +27,7 @@ import org.apache.solr.client.solrj.io.eval.StreamEvaluator;import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;import org.junit.Test;-import org.junit.Assert;+import junit.framework.Assert;public class DivideEvaluatorTest extends SolrTestCase {diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/EqualToEvaluatorTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/EqualToEvaluatorTest.javaindex ff6339fffcc..6cdbfcfd769 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/EqualToEvaluatorTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/EqualToEvaluatorTest.java@@ -28,7 +28,7 @@ import org.apache.solr.client.solrj.io.eval.StreamEvaluator;import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;import org.junit.Test;-import org.junit.Assert;+import junit.framework.Assert;public class EqualToEvaluatorTest extends SolrTestCase {diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ExclusiveOrEvaluatorTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ExclusiveOrEvaluatorTest.javaindex 0d862170443..d63ca6a4646 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ExclusiveOrEvaluatorTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/ExclusiveOrEvaluatorTest.java@@ -26,7 +26,7 @@ import org.apache.solr.client.solrj.io.eval.StreamEvaluator;import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;import org.junit.Test;-import org.junit.Assert;+import junit.framework.Assert;public class ExclusiveOrEvaluatorTest extends SolrTestCase {diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/FieldValueEvaluatorTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/FieldValueEvaluatorTest.javaindex de31faef576..f87c7f9b057 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/FieldValueEvaluatorTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/FieldValueEvaluatorTest.java@@ -27,7 +27,7 @@ import org.apache.solr.client.solrj.io.Tuple;import org.apache.solr.client.solrj.io.eval.FieldValueEvaluator;import org.junit.Test;-import org.junit.Assert;+import junit.framework.Assert;public class FieldValueEvaluatorTest extends SolrTestCase {diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/FloorEvaluatorTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/FloorEvaluatorTest.javaindex e0aa3e24aa3..3ac678cfdc9 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/FloorEvaluatorTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/FloorEvaluatorTest.java@@ -27,7 +27,7 @@ import org.apache.solr.client.solrj.io.eval.StreamEvaluator;import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;import org.junit.Test;-import org.junit.Assert;+import junit.framework.Assert;public class FloorEvaluatorTest extends SolrTestCase {diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/GreaterThanEqualToEvaluatorTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/GreaterThanEqualToEvaluatorTest.javaindex 50e8cad8e7b..09d0c0d616f 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/GreaterThanEqualToEvaluatorTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/GreaterThanEqualToEvaluatorTest.java@@ -27,7 +27,7 @@ import org.apache.solr.client.solrj.io.eval.StreamEvaluator;import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;import org.junit.Test;-import org.junit.Assert;+import junit.framework.Assert;public class GreaterThanEqualToEvaluatorTest extends SolrTestCase {diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/ops/ConcatOperationTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/ops/ConcatOperationTest.javaindex ef523dfe5a6..bbc6755ccaa 100644--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/ops/ConcatOperationTest.java+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/ops/ConcatOperationTest.java@@ -18,7 +18,7 @@ package org.apache.solr.client.solrj.io.stream.ops;import java.util.Map;-import org.junit.Assert;+import junit.framework.Assert;import org.apache.commons.collections.map.HashedMap;import org.apache.solr.SolrTestCase;diff --git a/solr/solrj/src/test/org/apache/solr/common/util/JsonValidatorTest.java b/solr/solrj/src/test/org/apache/solr/common/util/JsonValidatorTest.javaindex 0d8cdec8c0a..8c062667479 100644--- a/solr/solrj/src/test/org/apache/solr/common/util/JsonValidatorTest.java+++ b/solr/solrj/src/test/org/apache/solr/common/util/JsonValidatorTest.java@@ -179,7 +179,6 @@ public class JsonValidatorTest extends SolrTestCaseJ4 {assertNull(object);}- @SuppressWarnings("rawtypes")private void checkSchema(String name) {ValidatingJsonMap spec = Utils.getSpec(name).getSpec();Map commands = (Map) spec.get("commands");diff --git a/solr/test-framework/src/java/org/apache/solr/SolrIgnoredThreadsFilter.java b/solr/test-framework/src/java/org/apache/solr/SolrIgnoredThreadsFilter.javaindex 3fce31db253..48c14828047 100644--- a/solr/test-framework/src/java/org/apache/solr/SolrIgnoredThreadsFilter.java+++ b/solr/test-framework/src/java/org/apache/solr/SolrIgnoredThreadsFilter.java@@ -59,11 +59,6 @@ public class SolrIgnoredThreadsFilter implements ThreadFilter {if (threadName.startsWith("Image Fetcher")) {return true;}-- if (threadName.startsWith("Log4j2-TF-2-AsyncLoggerConfig")) {- return true;- }-return false;}diff --git a/solr/test-framework/src/java/org/apache/solr/SolrTestCase.java b/solr/test-framework/src/java/org/apache/solr/SolrTestCase.javaindex 235b31d224e..c4c40e74b2b 100644--- a/solr/test-framework/src/java/org/apache/solr/SolrTestCase.java+++ b/solr/test-framework/src/java/org/apache/solr/SolrTestCase.java@@ -28,7 +28,6 @@ import org.slf4j.Logger;import org.slf4j.LoggerFactory;import static com.carrotsearch.randomizedtesting.RandomizedTest.systemPropertyAsBoolean;-import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;/*** All Solr test cases should derive from this class eventually. This is originally a result of async logging, see:@@ -41,7 +40,7 @@ import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;* Other changes that should affect every Solr test case may go here if they don't require the added capabilities in* SolrTestCaseJ4.*/-@ThreadLeakFilters(defaultFilters = true, filters = { SolrIgnoredThreadsFilter.class })+public class SolrTestCase extends LuceneTestCase {private static final Logger log = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());