Commit Graph

15245 Commits

Author SHA1 Message Date
Isabel Drost-Fromm 17959871ff Merge pull request #12414 from MaineC/feature/10885
Adds template support to _msearch resource

Much like we already do with search this adds templating support to the _msearch resource.

Closes #10885
2015-09-02 10:21:36 +02:00
Britta Weber 9f49e0e7c1 Merge pull request #13246 from brwe/read-post-recovery
Allow reads on shards that are in POST_RECOVERY
2015-09-02 09:46:01 +02:00
Britta Weber 89ac6a83f1 Allow reads on shards that are in POST_RECOVERY
Currently, we do not allow reads on shards which are in POST_RECOVERY which
unfortunately can cause search failures on shards which just recovered if there no replicas (#9421).
The reason why we did not allow reads on shards that are in POST_RECOVERY is
that after relocating a shard might miss a refresh if the node that executed the
refresh is behind with cluster state processing. If that happens, a user might execute
index/refresh/search but still not find the document that was indexed.

We changed how refresh works now in #13068 to make sure that shards cannot miss a refresh this
way by sending refresh requests the same way that we send write requests.

This commit changes IndexShard to allow reads on POST_RECOVERY now.
In addition it adds two test:

- test for issue #9421 (After relocation shards might temporarily not be searchable if still in POST_RECOVERY)
- test for visibility issue with relocation and refresh if reads allowed when shard is in POST_RECOVERY

closes #9421
2015-09-02 09:42:36 +02:00
Robert Muir 2a129f1868 Merge pull request #13263 from rmuir/improve_jacoco
Improve jacoco coverage
2015-09-01 22:39:59 -04:00
Robert Muir abec2679f0 Improve jacoco coverage
Upgrade jacoco version and allow it to run with security manager enabled.
2015-09-01 22:14:49 -04:00
Robert Muir 517f00b048 doc how to get code coverage for unit,integ,combined 2015-09-01 20:57:48 -04:00
Robert Muir e5a02b1d96 Remove unused goal to allow for integ test coverage analysis 2015-09-01 20:56:23 -04:00
Robert Muir 930a5ee170 Merge pull request #13244 from rmuir/lt
Lithuanian analysis
2015-09-01 15:42:58 -04:00
Ryan Ernst 768bfb7d1d Merge pull request #13206 from rjernst/mappings_broken
Fix numerous checks for equality and compatibility in mapper field types
2015-09-01 11:44:18 -07:00
Simon Willnauer 90c2b3a384 Add simple comparator tests Relates to #13249 2015-09-01 20:11:10 +02:00
Nik Everett 69b7feeb78 Merge pull request #13076 from nik9000/bats_plugins
Packaging: Install all plugins during bats tests
2015-09-01 13:44:15 -04:00
Nik Everett e4410482fe Packaging: Install all plugins during bats tests
Related to #12717
2015-09-01 13:43:56 -04:00
Britta Weber 7cbd0a1bf5 [test] delete index after test for repetition
DateHistogramIT has suite scope and therefore must take care of cleaning up after
each test. Otherwise we cannot run tests in several times with tests.iters.
2015-09-01 17:58:34 +02:00
Adrien Grand c6d282f9f6 Remove extra licenses 2015-09-01 17:44:57 +02:00
Adrien Grand 3619cce53b Update licenses for analysis plugins. 2015-09-01 15:21:49 +02:00
Nik Everett af394443e0 Merge pull request #13226 from nik9000/docs_position_increment_gap
[docs] Fix docs for position_increment_gap
2015-09-01 09:11:28 -04:00
Adrien Grand 656fa69f2d Merge pull request #13243 from llasram/hll-estimate-bias-nn-k-6
Estimate HyperLogLog bias via k-NN regression
2015-09-01 14:59:17 +02:00
Robert Muir 0d3e3f81fc Lithuanian analysis 2015-09-01 08:52:10 -04:00
Marshall Bockrath-Vandegrift 1c773e235a Estimate HyperLogLog bias via k-NN regression
The implementation this commit replaces was almost k-NN regression with
k=2, but had two bugs: (a) it depends on the empirical raw estimates
being in strictly non-decreasing order for the binary search (which they
are not); and (b) it weights the biases positively with increased
distance from the corresponding raw estimate.

“HyperLogLog in Practice” leaves the choice of exact algorithm here
fairly vague, just noting: “We use k-nearest neighbor interpolation to
get the bias for a given raw estimate (for k = 6).”  The majority of
other open source HyperLogLog++ implementations appear to use k-NN
regression with uniform weights (and generally k = 6).  Uniform
weighting does decrease variance, but also introduces bias at the domain
extrema.  This problem, plus the use of the word “interpolation” in the
original paper, suggests (inverse) distance-weighted k-NN, as
implemented here.
2015-09-01 08:42:29 -04:00
Adrien Grand 7bc1acf956 Merge pull request #13239 from jpountz/upgrade/lucene-5.3.0
Upgrade to lucene-5.3.0.
2015-09-01 14:03:29 +02:00
Clinton Gormley 20921fcc3d Document transport.ping_schedule
Closes #13241
2015-09-01 13:43:17 +02:00
Britta Weber d386d909fc rename actions back to admin/* and add suffix [s] instead 2015-09-01 12:53:07 +02:00
Jason Tedor edac404f22 Merge pull request #13023 from jasontedor/enforce-maven-version
Enforce supported Maven versions
2015-09-01 06:37:47 -04:00
Britta Weber 05b48b904d set timeout for refresh and flush to default
Since #13068 refresh and flush requests go to the primary first and are then replicated.
One difference to before is though that if a shard is  not available (INITIALIZING for example)
we wait a little for an indexing request but for refresh we don't and just give up immediately.
Before, refresh requests were just send to the shards regardless of what their state is.

In tests we sometimes create an index, issue an indexing request, refresh and
then get the document. But we do not wait until all nodes know that all primaries have ben assigned.
Now potentially one node can be one cluster state behind and not know yet that
the shards have ben started. If the refresh is executed through this node then the
refresh request will silently fail on shards that are started already because from
the nodes perspective they are still initializing. As a consequence, documents
that expected to be available in the test are now not.
Example test failures are here: http://build-us-00.elastic.co/job/elasticsearch-20-oracle-jdk7/395/

This commit changes the timeout to 1m (default) to make sure we don't miss shards
when we refresh. This will trigger the same retry mechanism as for indexing requests.
We still have to make a decision if this change of behavior is acceptable.

see #13238
2015-09-01 12:20:05 +02:00
Robert Muir 7caed74d5d Merge pull request #13232 from rmuir/nullcheck_policy
Add missing null check in ESPolicy.
2015-09-01 06:03:35 -04:00
Adrien Grand 5d9fb2e8a6 Upgrade to lucene-5.3.0.
From a user perspective, the main benefit from this upgrade is that the new
Lucene53Codec has disk-based norms. The elasticsearch directory has been fixed
to load these norms through mmap instead of nio.

Other changes include the removal of `max_thread_states`, the fact that
PhraseQuery and BooleanQuery are now immutable, and that deleted docs are now
applied on top of the Scorer API.

This change introduces a couple of `AwaitsFix`s but I don't think it should
hold us from merging.
2015-09-01 11:58:45 +02:00
Isabel Drost-Fromm 8cd86a615a Adds template support to _msearch resource
Much like we already do with search this adds templating support to the _msearch resource.

Closes #10885
2015-09-01 11:54:43 +02:00
Clinton Gormley 1ee6ea9247 Docs: index.codec is static, not dynamic
The `index.codec` setting can only be set on a closed index, not dynamically
2015-09-01 11:49:42 +02:00
Adrien Grand f0b7fa2f31 Merge pull request #13060 from andrestc/enhancement/functionscore-unmapped
Make FunctionScore work on unmapped field with `missing` parameter
2015-09-01 11:05:30 +02:00
Simon Willnauer 7571276b84 Pass in relevant disk usage map for early termination 2015-09-01 10:35:56 +02:00
xuzha f46e66e7d0 Remove the experimental indices.fielddata.cache.expire
closes #10781
2015-09-01 00:40:04 -07:00
Britta Weber 333831c126 Merge pull request #13068 from brwe/broadcast_replication
Make refresh a replicated action
2015-09-01 09:21:54 +02:00
Robert Muir a58c5dba89 Add missing null check in ESPolicy.
This allows reducing privileges with doPrivileged to work,
otherwise it will fail with NPE.

In general, if some code wants to do that, let it. The null
check is needed, even though ProtectionDomain(CodeSource, PermissionCollection)
is more than a bit misleading: "the current Policy will not be consulted".

Additionally add a defensive check for location, since the docs
there are even more confusing: https://bugs.openjdk.java.net/browse/JDK-8129972

The jdk policy impl has both these checks.
2015-09-01 00:34:34 -04:00
Jason Tedor aea00a62f3 Merge pull request #13227 from jasontedor/immutable-lists-be-gone
Remove and forbid use of com.google.common.collect.ImmutableList
2015-08-31 15:29:35 -04:00
Martijn van Groningen 238b56dedf Merge pull request #13046 from jimhooker2002/issue-4665-clean
Turn DestructiveOperations into a Guice module.

To share the same instance between component inside a node.

Closes #4665
2015-08-31 21:22:55 +02:00
Martijn van Groningen 51d052c32a Merge pull request #13215 from martijnvg/tests/enable_mock_modules
Allow tests to override whether mock modules are used
2015-08-31 21:11:34 +02:00
Martijn van Groningen 30ffa9a61b test: Allow tests to override whether mock modules are used 2015-08-31 21:02:49 +02:00
Jason Tedor a8bace9f97 Remove and forbid final uses of ImmutableList 2015-08-31 14:35:23 -04:00
Jason Tedor b0af7a1426 Fix NettyTransport 2015-08-31 14:29:00 -04:00
Jason Tedor e39a3bae2c Merge branch 'master' into lists_are_simple 2015-08-31 14:07:00 -04:00
Nik Everett da16dcf527 [docs] Fix docs for position_increment_gap
Closes #13207
2015-08-31 14:05:55 -04:00
Britta Weber d81f426b68 Make refresh a replicated action
prerequisite to #9421
see also #12600
2015-08-31 19:44:00 +02:00
Martijn van Groningen 1230cb0278 Merge pull request #13222 from martijnvg/tests/external_tests_provide_transport_client_with_plugins
Provide the plugins to transport client communicating with the the external cluster
2015-08-31 17:06:53 +02:00
Tanguy Leroux db7aecab4d update list of available os stats
os cpu information is no longer exposed through the nodes stats api
2015-08-31 17:03:45 +02:00
Martijn van Groningen 1b84cadb7b test: The transport client that interacts with the external cluster shoud be provided a list of transport client plugins. 2015-08-31 16:58:03 +02:00
Nik Everett a3616e9aec Merge pull request #13221 from nik9000/force_virtualbox
Lock vagrant to virtualbox
2015-08-31 10:54:26 -04:00
Nik Everett fb561ce228 [docs] Lock vagrant to virtualbox 2015-08-31 10:52:09 -04:00
Nik Everett 23c1766cdc [packaging] Lock vagrant to virtualbox
Virtualbox is the default virtualization provier for vagrant but folks
override that from time to time. If they do then the build will fail because
the boxes used by the build don't usually support non-virtualbox providers.

Closes #13217
2015-08-31 10:45:46 -04:00
Simon Willnauer 66b78341e4 Add note about multi data path and disk threshold deciders
Prior to 2.0 we summed up the available space on all disk on a node
due to the raid-0 like behavior. Now we don't do this anymore and use the
min & max disk space to make decisions.

Closes #13106
2015-08-31 16:23:54 +02:00
Britta Weber a7e240077d Merge pull request #13218 from brwe/resolve-index-default-impl
add default impl for resolveIndex()
2015-08-31 15:53:57 +02:00