31676 Commits

Author SHA1 Message Date
Simon Willnauer
c483f6bc59 LUCENE-8671: Load FST off-heap if reader is not opened from an index writer (#610)
Today we never load FSTs of ID-like fields off-heap since we need
very fast access for updates. Yet, a reader that is not loaded from
an IndexWriter can also leave the FST on disk. This change adds
this information to SegmentReadState to allow the postings format
to make this decision without configuration.
2019-03-20 11:29:06 +01:00
Uwe Schindler
c0781e9fc7 LUCENE-8729: Workaround to allow compile under JDK13+ 2019-03-19 19:06:36 +01:00
David Smiley
8f25ded16f SOLR-13253: avoid using IndexSchema.getResourceLoader for non-schema things.
Furthermore it's reference to SolrConfig was removed.

(cherry picked from commit 85a702cdff23a6352945dd78eb54ff6db68f6965)
2019-03-19 13:52:38 -04:00
Bar Rotstein
de58717183 SOLR-12955: Refactored DistributedUpdateProcessor to put SolrCloud specifics into a subclass
Closes #528

(cherry picked from commit 5b7866b0851eff66cb7e929beef5249e3c72ac36)
2019-03-19 13:28:27 -04:00
Andrzej Bialecki
b778417054 SOLR-11127: REINDEXCOLLECTION command for re-indexing of existing collections. 2019-03-19 13:47:44 +01:00
Adrien Grand
83c30303ed LUCENE-8138: Check that dv producers's next/advance and advanceExact impls are consistent. 2019-03-19 13:35:07 +01:00
Adrien Grand
1d9f00fd5e LUCENE-8166: Require merge instances to be consumed in the thread that created them. 2019-03-19 13:35:07 +01:00
Kevin Risden
105979fb4c
SOLR-8033: Remove debug if branch in HdfsTransactionLog
Signed-off-by: Kevin Risden <krisden@apache.org>
2019-03-19 06:20:47 -04:00
Kevin Risden
6064b03ac6
SOLR-13330: Improve HDFS tests
Related JIRAs:
* SOLR-11010
* SOLR-11381
* SOLR-12040
* SOLR-13297

Changes:
* Consolidate hdfs configuration into HdfsTestUtil
* Ensure socketTimeout long enough for HDFS tests
* Ensure HdfsTestUtil.getClientConfiguration used in tests
* Replace deprecated HDFS calls
* Use try-with-resources to ensure closing of HDFS resources

Signed-off-by: Kevin Risden <krisden@apache.org>
2019-03-19 05:27:46 -04:00
erick
0894e39ceb SOLR-13268: Patch that flushes when shutting down 2019-03-18 11:53:54 -07:00
Alan Woodward
13aac3becd LUCENE-8694: Payload-filtered term intervals 2019-03-18 10:12:51 +00:00
Chris Hostetter
695bfa3c90 SOLR-12923: Mea culpa: Remove useless import of java.lang... that breaks precommit
(cherry picked from commit 5c143022e7abcdf14a570786afec4ff099fd581c)
2019-03-15 14:39:42 -07:00
Chris Hostetter
87ec0c3600 SOLR-12923: fix SimClusterStateProvider to use lock.lockInterruptibly() exclusively, and make SimCloudManager's Callable checks tollerant of Callables that may have failed related to interrupts w/o explicitly throwing InterruptedException
(cherry picked from commit 1a54c6b19db9dcb1081e43614bf479e0ac7bf177)
2019-03-15 14:24:07 -07:00
Chris Hostetter
0ac45c1668 SOLR-12923: tweak the randomization in testCreateLargeSimCollections to reduce the max possible totalCores
also decrease the number of iters while increase the cluster shape wait time to reduce the risk of spurious failures on machines under heavy contention w/o making the the test any slower on average

(cherry picked from commit c79aeee5f9a013c280a76a8d6b04bea63f212909)
2019-03-15 14:24:07 -07:00
Chris Hostetter
653ba8d245 SOLR-12923: Fix some issues w/concurrency and exception swallowing in SimClusterStateProvider/SimCloudManager
There are 3 tightly related bug fixes in these changes:

1) ConcurrentModificationExceptions were being thrown by some SimClusterStateProvider methods when
   creating collections/replicas due to the use of ArrayLists nodeReplicaMap. These ArrayLists were changed
   to use synchronizedList wrappers.
2) The Exceptions from #1 were being swallowed/hidden by code using SimCloudManager.submit() w/o checking
   the result of the resulting Future object. (As a result, tests waiting for a particular ClusterShape
   would timeout regardless of how long they waited.)   To protect against "silent" failures like this,
   this SimCloudManager.submit() has been updated to wrap all input Callables such that any uncaught errors
   will be logged and "counted."  SimSolrCloudTestCase will ensure a suite level failure if any such failures
   are counted.
3) The changes in #2 exposed additional concurrency problems with the Callables involved in leader election:
   These would frequently throw IllegalStateExceptions due to assumptions about the state/existence of
   replicas when the Callables were created vs when they were later run -- notably a Callable may have been
   created that held a reference to a Slice, but by the time that Callable was run the collection (or a
   node, etc...) refered to by that Slice may have been deleted.  While fixing this, the leader election
   logic was also cleaned up such that adding a replica only triggers leader election for that shard, not
   every shard in the collection.

While auditing this code, cleanup was also done to ensure all usage of SimClusterStateProvider.lock was
also cleaned up to remove all risky points where an exception may have been possible after aquiring the
lock but before the try/finally that ensured it would be unlocked.

(cherry picked from commit 76babf876a49f82959cc36a1d7ef922a9c2dddff)
2019-03-15 14:24:07 -07:00
Simon Willnauer
da6522511c Fix more tests to not use concurrent flushing in RIW#commit() 2019-03-15 22:18:24 +01:00
Jan Høydahl
4540fa427a SOLR-13244: Nodes view fails when a node is temporarily down
(cherry picked from commit 8f29d1eaadce5ca2c79b1f48161a8dda696d9952)
2019-03-15 13:31:34 +01:00
Andrzej Bialecki
f7e41ef868 SOLR-13292: Fix a logic bug when point types are present, add more details to the unit test. 2019-03-15 11:54:13 +01:00
Simon Willnauer
9ccac0f1bb Improve RIW exception handling and opt out of concurrent flushing if exception is expected 2019-03-15 11:00:13 +01:00
Adrien Grand
d89387553d LUCENE-8688: Forced merges merge more than necessary. 2019-03-15 10:29:33 +01:00
Alan Woodward
ecf86ecab7 LUCENE-3041: QueryVisitor (#581)
This commit adds an introspection API to Query, allowing users to traverse
the nested structure of a query and examine its leaves.  It replaces the existing
`extractTerms` method on Weight, and alters some highlighting code to use
the new API
2019-03-15 08:29:32 +00:00
Simon Willnauer
1c50a27cd4 Concurrently flush next buffer during commit in RandomIndexWriter (#607)
This is a spinn-off from `LUCENE-8700` that is satisfied by IndexWriter#flushNextBuffer.
The idea here is to additionally call flushNextBuffer in RandomIndexWriter for better
test coverage. This is a test-only change.
2019-03-14 15:44:29 +01:00
Moshe
7961e17e7e SOLR-13129: nested docs: add more/better documentation in Solr ref-guide
(cherry picked from commit c2a6772f1edd506c114a4e8179bd09e928f97b49)
2019-03-14 09:12:41 -04:00
jimczi
6e0afdb15d Add 8.0.0 back compat test indexes 2019-03-14 13:23:55 +01:00
jimczi
d596b13ca3 update doap files with the new release 8.0.0 2019-03-14 13:04:32 +01:00
Alan Woodward
6571d06c25 LUCENE-8719: Traverse all paths at the end of a TokenStream in FixedShingleFilter 2019-03-14 11:21:55 +00:00
Alan Woodward
003edafdc8 LUCENE-8726: Changes entry 2019-03-14 10:57:23 +00:00
Alan Woodward
ce5ec573f6 LUCENE-8726: ValueSource.asDoubleValuesSource() could leak a reference to IndexSearcher 2019-03-14 10:19:13 +00:00
Jan Høydahl
e68d16f32c SOLR-12121: Remove a System.out.println in JWTAuthPlugin
(cherry picked from commit a18aa2118bf53bed0bf512820e066a2fa9f018b1)
2019-03-14 10:52:32 +01:00
Shalin Shekhar Mangar
cedff86aaa SOLR-13234: Fix for turkish locales
WhenSolrExporterIntegrationTest.jvmMetrics ran on a JVM with the Turkish locale, (test seed: 62880F3B9F140C89). The JVM metric for terminated thread-count has a dotless-i e.g. termınated.
This causes the check for matching metrics to fail.

We could normalize the text in this case, however I think it's better to ensure we have the correct total number of JVM thread metrics rather than looking at Prometheus labels which maybe localized.

This closes #605.

(cherry picked from commit 6d0386c901b9d14c7464c7cf286d4a005eb9c72c)
2019-03-14 11:12:35 +05:30
Gus Heck
1d85f13eeb SOLR-13131 Category Routed Aliases
(cherry picked from commit d8f2a02fdb11a484425f9fddfa7061711d2f0034)
2019-03-13 01:36:40 -04:00
Gus Heck
39adb09fc9 Remove inadvertently included println 2019-03-12 16:07:02 -04:00
Mike McCandless
c9de94c663 LUCENE-8720: fix int overflow in NameIntCacheLRU 2019-03-12 12:20:12 -04:00
Gus Heck
470813143d SOLR-12891 MacroExpander will no longer will expand URL parameters by
default inside of the 'expr' parameter, add InjectionDefense class
for safer handling of untrusted data in streaming expressions and add
-DStreamingExpressionMacros system property to revert to legacy behavior

(cherry picked from commit 9edc557f4526ffbbf35daea06972eb2c595e692b)
2019-03-12 11:56:28 -04:00
Yeongsu Kim
8d0652451e LUCENE-8631: The Korean user dictionary now picks the longest-matching word and discards the other matches. 2019-03-12 10:26:26 +01:00
jimczi
4d351cf066 LUCENE-8652: remove unused import 2019-03-12 09:56:50 +01:00
jimczi
d01dc484e9 LUCENE-8652: ensure that the norm doesn't influence the score in TestSynonymQuery#testBoosts 2019-03-12 09:34:56 +01:00
iverase
31809b3e27 LUCENE-8713: Add Line2D tests 2019-03-12 09:19:48 +01:00
Ignacio Vera
c70a404d07 LUCENE-8712: Polygon2D does not detect crossings in some cases (#598)
LUCENE-8712: revert crossing logic to use boolean logic and skip lines
over the dateline to support dateline crossing logic
2019-03-12 08:45:16 +01:00
Erick Erickson
a87ba09e11 SOLR-13268: Clean up any test failures resulting from defaulting to async logging. Put TestXmlQParser back
(cherry picked from commit b893548d97f8b04b40dfbebd79bd860603b92c63)
2019-03-11 21:42:37 -07:00
Erick Erickson
6f6fbf0be2 SOLR-12732: TestLogWatcher failure on Jenkins. Deal with superclass logging bleeding into first watcher in the test 2019-03-11 13:00:26 -07:00
Erick Erickson
132f543310 SOLR-13268: Clean up any test failures resulting from defaulting to async logging. Fix precommit test to not include the baseDir
(cherry picked from commit 3a1603dab349fa828217fe1146e73c6a5f1a4fcf)
2019-03-11 11:07:28 -07:00
jimczi
24427f9f5c LUCENE-8652: SynonymQuery can now deboost the document frequency of each term when blending the score of the synonym 2019-03-11 18:17:34 +01:00
Chris Hostetter
44ff1c0ef9 SOLR-13300: DistributedFacetExistsSmallTest should not attempt to compare results of a query that is known to differ in behavior in distributed mode
(cherry picked from commit 7eb728a611a5cad82e44bd662294d682353a2ccb)
2019-03-11 10:03:07 -07:00
Kevin Risden
b4d9a98b32
SOLR-13307: Ensure HDFS tests clear System properties they set (Kevin Risden)
Signed-off-by: Kevin Risden <krisden@apache.org>
2019-03-11 11:22:22 -04:00
Mikhail Khludnev
5a5a39ee18 SOLR-13284: fallback to json instead of NPE and 500 code, when wt is omitted or wrong. 2019-03-10 23:12:22 +03:00
erick
277251c202 SOLR-13268: Clean up any test failures resulting from defaulting to async logging
(cherry picked from commit 9272c29)
2019-03-10 11:35:51 -07:00
Andrzej Bialecki
f6f5f995ef SOLR-13292: Provide extended per-segment status of a collection. 2019-03-09 14:09:34 +01:00
Erick Erickson
83ab355772 SOLR-12732: TestLogWatcher failure on Jenkins. Added more logging
(cherry picked from commit 8c6e30536562413639eaf8bab1087da700733b33)
2019-03-08 21:43:08 -08:00
Chris Hostetter
7ebd7f2fa5 Merge remote-tracking branch 'refs/remotes/origin/branch_8x' into branch_8x 2019-03-08 14:55:05 -07:00