Commit Graph

8136 Commits

Author SHA1 Message Date
Martijn van Groningen 64c43c6dc0 Made the include and exclude support for terms and significant terms aggregations based on global ordinals.
Closes #6000
2014-05-12 13:14:13 +02:00
javanna 7980911d96 restored @Test annotation in SimpleValidateQueryTests 2014-05-12 12:52:48 +02:00
Alex Marandon d1ddbd2c51 Detect unsupported fields after query in validate query api
The validate API was failing to reject JSON input that had unsupported
fields placed after a supported field. This was causing invalid requests
to be reported as valid.

Fixes #5685
2014-05-12 12:49:25 +02:00
javanna 3d63bac51d Fixed validate query parsing issues
Made sure that a match_all query is used when no query is specified and ensure no NPE is thrown either.
Also used the same code path as the search api to ensure that alias filters are taken into account, same for type filters.

Closes #6111 Closes #6112 Closes #6116
2014-05-12 12:49:25 +02:00
Alex Ksikes 513f25ae97 More Like This: Fix correct use of size and from parameters
More Like This API would not take into account 'size' and 'from' in request body parameters.
Instead these values would always be overriden by the default values of REST parameters
'search_size' and 'search_from'.

Closes #5981
2014-05-12 12:30:04 +02:00
Martijn van Groningen d4d6c3459e [TEST] Make sure all shards are allocated before the delete type is being executed. 2014-05-12 11:59:09 +02:00
Adrien Grand ebfab19400 [TESTS] Disable BenchmarkIntegrationTest#testSubmitBenchmark until it is fixed. 2014-05-12 11:30:01 +02:00
David Pilato 645efa05df Update shade-plugin to 2.3
Shade-plugin 2.2 does not work with JDK8 (see http://jira.codehaus.org/browse/MSHADE/fixforversion/19828)
2014-05-12 10:23:49 +02:00
Martijn van Groningen 145efbf6ea Return missing (404) is a scroll_id is cleared that no longer exists.
Closes #5730
2014-05-12 09:43:56 +02:00
Adrien Grand 51de01bae5 [TESTS] Tentative fix of BigArrays byte-accounting checks. 2014-05-12 09:25:49 +02:00
Clinton Gormley 4fefe628b0 [TEST] Aborting a non-existent benchmark throws a missing request 2014-05-10 13:09:30 +02:00
javanna 4331021361 enable dynamic scripts in release node, otherwise REST tests will fail
Relates to #5853
2014-05-10 11:16:25 +02:00
cccabot 58ebcf1252 Fixed typos in FieldSortBuilder 2014-05-10 02:57:51 +02:00
Andrew Selden 48879752a2 [TEST] Fix for benchmark tests
- Fix bug where repeatedly calling computeSummaryStatistics() could
  accumulate some values incorrectly
- Fix check for number of responsive nodes on list is <= number of
  candidate benchmark nodes
- Add public getters for summary statistics
- Add javadoc for new getters
- Add javadoc comments about API use
- Improve abort and status tests by calling awaitBusy() to wait for jobs
  to be completely submitted before testing them
2014-05-09 16:01:57 -07:00
mikemccand 5e40a4b95a don't call isFinite from XAnalyzingSuggester; re-enable test on Java 8 2014-05-09 18:24:13 -04:00
Lee Hinman 90e019b4a4 [TEST] Add test specifying fields field /_cat/fielddata REST test 2014-05-09 23:57:23 +02:00
javanna 6678da8c28 [TEST] randomly added node.bench=true to client node in test cluster and re-enabled REST benchmark tests based on number of bench nodes available
In our REST tests we already have support for features and skip sections that allow to skip tests if a feature is not supported.
We can then add a skip section based on the benchmark feature to the benchmark tests and execute them only when they are supported, knowing that they need at least a node with node.bench settings within the cluster. We can check that this requirement is met by calling the nodes info api.

This way we can dynamically decide whether to execute those tests or not and we don't need to have a node.bench around all the time. In fact, given that the REST tests use the GLOBAL cluster, we want to be able to randomize settings as much as possible and run tests against default settings as well. Also, this mechanism can be easily supported by the external cluster implementation that is used during the release process.

Introduced ability to disable benchmark nodes which is needed by BenchmarkNegativeTest.
2014-05-09 23:36:00 +02:00
Alex Ksikes d8bb7c157a [TEST] Removed the restriction on the number of bool clauses that must match.
The test failed because 'percent_terms_to_match' defaults to 0.3, which results
in requiring that some terms only found in the queried document must match, when
all the documents are on the same shard.
2014-05-09 19:14:32 +02:00
Lee Hinman 7847ec0a6c Fix typo in path specification for /_cat/fielddata 2014-05-09 15:03:51 +02:00
Lee Hinman e7e4ef859a Add /_cat/fielddata to display fielddata usage
Closes #4593
2014-05-09 13:18:02 +02:00
Alex Ksikes dae48d9fe8 Added the ability to include the queried document for More Like This API.
By default More Like This API excludes the queried document from the response.
However, when debugging or when comparing scores across different queries, it
could be useful to have the best possible matched hit. So this option lets users
explicitly specify the desired behavior.

Closes #6067
2014-05-09 12:59:39 +02:00
Alex Ksikes 48b7172ee7 Provided some insights as to how More Like This works internally.
In the Google Groups forum there appears to be some confusion as to what mlt
does. This documentation update should hopefully help demystifying this
feature, and provide some understanding as to how to use its parameters.

Closes #6092
2014-05-09 12:13:29 +02:00
Clinton Gormley a972aaa7ae [TEST] Temporarily added a wait-for-yellow to delete_mapping tests
Should be removed once #5997 is fixed
2014-05-09 12:04:34 +02:00
mikemccand aa31c71776 mute this test until we fix isFinite 2014-05-09 05:24:22 -04:00
Martijn van Groningen 67fe88c63c [TEST] Enforce that only one shard per node is allocated. The prevents during node shutdown, that a second shard is assigned the another node. 2014-05-09 10:43:08 +02:00
javanna bd2a616c82 [DOCS] fixed broken json in multi term vectors docs 2014-05-08 16:01:13 +02:00
javanna 2999152e19 [DOCS] fixed typo in multi term vectors docs 2014-05-08 15:50:24 +02:00
Clinton Gormley e0a45459a4 [TEST] cat.recovery with replicas can have 100.0% 2014-05-08 15:40:28 +02:00
Clinton Gormley eb6d3e3eb3 [TEST] Fixed pathological regex in cat.recovery
Fixes #6070
2014-05-08 14:15:47 +02:00
Martijn van Groningen d7c05e5924 Temporarily disabling benchmark tests.
Relates #6094
2014-05-08 13:18:12 +02:00
Ivan Brusic bac0627c5e Update fielddata.asciidoc
Spelling correction
2014-05-08 10:59:24 +02:00
Ivan Brusic 59e0c34cdb Update fielddata.asciidoc
Fixed default value for circuit breaker
2014-05-08 10:58:10 +02:00
Martijn van Groningen d5b95e3e8a A number of changes to fix reduce failures if shard failures have occurred:
* The shardTopDocs array should get created with the size equal to the total number of shard level requests and not the total number of requests that have a shard level result.
* Make sure no null TopDocs entires are passed down to TopDocs#merge
* Added dedicated scroll tests that tests scrolling on an index that has missing shards due to node failure.
* Made sure that the sort fields in SimpleNestedTests exists by adding the fields in the mapping during index creation.

Closes #6022
2014-05-08 10:17:00 +02:00
Martijn van Groningen e2a2f13f17 Added FilteredQuery to the list of forbidden apis 2014-05-08 09:54:10 +02:00
Martijn van Groningen 0efeeff49a The percolator needs to deleted percolator documents into account when running in near realtime mode.
This bug only occurs in non-realtime mode when query, filter, facet or aggs is used.

Closes #5843
Closes #5840
2014-05-08 09:52:27 +02:00
Andrew Selden c00120b818 Fix for benchmark test
- Fix bug where repeatedly calling computeSummaryStatistics() could
  accumulate some values incorrectly.
- Fix check for number of responsive nodes on list is <= number of
  candidate benchmark nodes.
- Add public getters for summary statistics
- Add javadoc for new getters
- Add javadoc comments about API use
2014-05-07 18:42:39 -07:00
mikemccand 82aad78ff2 it's safe to use OneMerge.getTotalBytesSize (fixed in LUCENE-4775) 2014-05-07 17:25:06 -04:00
Andrew Selden f23274523a Integration tests for benchmark API.
- Randomized integration tests for the benchmark API.
- Negative tests for cases where the cluster cannot run benchmarks.
- Return 404 on missing benchmark name.
- Allow to specify 'types' as an array in the JSON syntax when describing a benchmark competition.
- Don't record slowest for single-request competitions.

Closes #6003, #5906, #5903, #5904
2014-05-07 14:14:54 -07:00
Andrew Selden f739abe89e Fix stack overflow in _cat/recovery test.
This fixes a stack overflow in the test for the _cat/recovery API.
The regular expression that tests the response body was modified to
handle large responses properly.
2014-05-07 13:58:00 -07:00
Andrew Selden 35f046e24f Fix _cat/allocation rest test
The rest test for _cat/allocation was failing due to a regular
expression not accounting for space-padded right-justified text.

Also added Improvements to regular expressions to be smarter about optional values
and to use '+' instead of '*' where applicable.
2014-05-07 13:10:31 -07:00
mikemccand 9daaae27b3 clarify that CMS defaults change is coming in 1.2 2014-05-07 13:49:54 -04:00
uboness fc52db1209 Changed the respnose structure of the percentiles aggregation where now all the percentiles are placed under a `values` object (or `values` array in case the `keyed` flag is set to `false`
Closes #5870
2014-05-07 18:35:24 +02:00
Chris Earle 12f758e811 [DOCS] Update nodes documentation with all headers
Adds a table with the exhaustive list of all available headers with a brief description (mostly from `org.elasticsearch.rest.action.cat.RestNodesAction`) so that people do not need to go searching for them in the code like I did, or search through `nodes?help`.
2014-05-07 11:18:22 -05:00
Shay Banon 743dc19acb Node version sometimes empty in _cat/nodes
closes #5480
2014-05-07 18:08:11 +02:00
Britta Weber 7944369fd1 Add `shard_min_doc_count` parameter for significant terms similar to `shard_size`
Significant terms internally maintain a priority queue per shard with a size potentially
lower than the number of terms. This queue uses the score as criterion to determine if
a bucket is kept or not. If many terms with low subsetDF score very high
but the `min_doc_count` is set high, this might result in no terms being
returned because the pq is filled with low frequent terms which are all sorted
out in the end.

This can be avoided by increasing the `shard_size` parameter to a higher value.
However, it is not immediately clear to which value this parameter must be set
because we can not know how many terms with low frequency are scored higher that
the high frequent terms that we are actually interested in.

On the other hand, if there is no routing of docs to shards involved, we can maybe
assume that the documents of classes and also the terms therein are distributed evenly
across shards. In that case it might be easier to not add documents to the pq that have
subsetDF <= `shard_min_doc_count` which can be set to something like
`min_doc_count`/number of shards  because we would assume that even when summing up
the subsetDF across shards `min_doc_count` will not be reached.

closes #5998
closes #6041
2014-05-07 18:02:56 +02:00
javanna f554178fc7 Renamed IndicesOptions#strict and IndicesOptions#lenient to make it clearer what they actually return, reused methods and introduced new one
Relates to #6059, where two new constants were introduced in IndicesOptions. There were already two constants there though, one of which we could have reused. This commit tries to unify them.
2014-05-07 17:40:57 +02:00
Alexander Reelsen 0c0f717aba Removed Index Status API
The functionality of the index status API has been replaced by the recovery API.

Relates #4854
2014-05-07 16:57:19 +02:00
Richard Boulton fdb5eb6555 Update keyword-tokenizer.asciidoc 2014-05-07 15:04:07 +02:00
Adrien Grand c49276cda7 Add a dedicated field data type for the _index field mapper.
This makes aggregations work on the _index field, and also allows to remove the
special facet aggregator for the _index field.

Close #5848
2014-05-07 14:06:13 +02:00
Adrien Grand c4f127fb6f Limit the number of bytes that can be allocated to process requests.
This should prevent costly requests from killing the whole cluster.

Close #6050
2014-05-07 12:55:48 +02:00