Commit Graph

14640 Commits

Author SHA1 Message Date
Martijn van Groningen a14913f7b6 Left over from the `query_cache` to `request_cache` rename. 2015-07-27 13:28:15 +02:00
Britta Weber 20facccaf6 Merge pull request #11666 from brwe/meta-data-zen
[TEST] remove redundant tests and move to different suite
2015-07-27 12:40:11 +02:00
Britta Weber e44c5ff703 check if index is closed or was previously closed when gathering relevant indices to write meta state
When an index is opened it will not be assigned to a node but also not have closed state
anymore. Before we only checked if an index either is closed or assigned to the data node
and therefore the change from close->open was not written.
2015-07-27 12:35:25 +02:00
Britta Weber 2713e903ab [TEST] remove redundant tests and move to different suite
Some of the test for meta data are redundant. Also, since they
somewhat test service disruptions (start master with empty
data folder) we might move them to DiscoveryWithServiceDisruptionsTests.
Also, this commit adds a test for
https://github.com/elastic/elasticsearch/issues/11665
2015-07-27 12:35:13 +02:00
Adrien Grand ec79568e6f Merge pull request #12430 from ruflin/ip_range-mask-fix
Fix cidr mask conversion issue for 0.0.0.0/0 and add tests #12005
2015-07-27 12:12:20 +02:00
javanna 8e931d5767 Query DSL: don't cache type filter in DocumentMapper
If we cache the type filter and we e.g. set its boost which is now settable on all queries, the boost will change for all subsequent queries. We should rather create a new query every time.
2015-07-27 11:35:19 +02:00
Ruflin 91d1789258 Move index creation to test setup method 2015-07-27 10:39:04 +02:00
Adrien Grand 00ae4bb792 Merge pull request #12465 from xuzha/xu-skip-hidden
skip hidden files
2015-07-27 10:06:45 +02:00
Ruflin b8c2f05ff5 Revert change to set longTo to "MAX_IP -1" and improve test suite to check for range 2015-07-27 09:11:04 +02:00
Shay Banon a99ccb6112 No need to find replica copy when index is created
There is no need to try and go fetch replica copies for best allocation when the index is created
2015-07-27 07:01:48 +09:00
xuzha b0b9c121c8 skip hidden files 2015-07-26 01:16:29 -07:00
Jason Tedor b3272fe648 Preserve the root cause when encountering an exception expecting to have reached the end of the setting stream 2015-07-25 15:29:15 -04:00
Martijn van Groningen c73fff799d Cleaned up the data structures used in MetaData for alias and index lookups.
Major changes:
* Changed MetaData to holds alias and index lookup information into a single TreeMap instead of two separate maps.
* Moved the building of the alias / index lookup to the metadata builder.
2015-07-24 22:04:11 +02:00
Jason Tedor 267afe866f Merge pull request #12451 from jasontedor/fix/12382
Add explicit check that we have reached the end of the settings stream when parsing settings
2015-07-24 13:52:00 -04:00
Christoph Büscher 3d53413650 Merge branch 'master' into feature/query-refactoring 2015-07-24 19:19:37 +02:00
Jason Tedor 8ac105dbb9 Add explicit check that we have reached the end of the settings stream when parsing settings
Settings are currently parsed by looping over the tokens until an END_OBJECT token is reached. However, this does not mean that the end of
the settings stream was reached. This can occur, for example, when parsing a YAML settings file with inconsistent indentation. Currently
in this case, some settings will be silently ignored. This commit forces a check that we have in fact reached the end of the settings
stream.

Closes #12382
2015-07-24 13:12:44 -04:00
Colin Goodheart-Smithe 3e0532a0c5 Aggregations: Add HDRHistogram as an option in percentiles and percentile_ranks aggregations
HDRHistogram has been added as an option in the percentiles and percentile_ranks aggregation. It has one option `number_significant_digits` which controls the accuracy and memory size for the algorithm

Closes #8324
2015-07-24 17:55:36 +01:00
javanna dbec71face Query DSL: assign result of validateInnerQuery in ConstantScoreQueryBuilder 2015-07-24 18:52:48 +02:00
Luca Cavanna 56391c14a6 Merge pull request #12447 from javanna/enhancement/dont_cache_type_query
Query DSL: don't cache type filter in DocumentMapper
2015-07-24 18:50:34 +02:00
javanna cf570ac5bd Query DSL: don't cache type filter in DocumentMapper
If we cache the type filter and we e.g. set its boost which is now settable on all queries, the boost will change for all subsequent queries. We should rather create a new query every time.
2015-07-24 18:37:17 +02:00
Christoph Büscher db5d73a617 Merge pull request #12444 from cbuescher/feature/query-refactoring-nullCheckCleanup
Query Refactoring: Move null-checks to validate
2015-07-24 18:17:36 +02:00
Adrien Grand e62aaa928e Tests: Fix TermVectorsUnitTests to not rely on HashMap iteration order. 2015-07-24 17:59:36 +02:00
Christoph Büscher 081d264f40 Merge branch 'master' into feature/query-refactoring 2015-07-24 17:57:17 +02:00
Robert Muir 219f48119c Merge pull request #12424 from rmuir/plugin_java_version
make java.version mandatory for jvm plugins
2015-07-24 11:37:15 -04:00
Christoph Büscher 15a09a04f2 Query Refactoring: Move null-checks from constructors and setters to validate
Following up to #12427, this PR does same changes, moving null-checks from construtors
and setters in query builder to the validate() method.

PR against query-refactoring branch
2015-07-24 17:36:25 +02:00
Robert Muir 980e564caa Merge branch 'master' into plugin_java_version 2015-07-24 11:12:52 -04:00
Alex Ksikes 76c03df035 Make sure filter is correctly parsed for multi-term vectors
This makes sure the `filter` parameter is correctly parsed in a multi-term
vector request when using `ids` and `parameters`.

Closes #12311
Closes #12312
2015-07-24 17:09:16 +02:00
Boaz Leskes 57cbce2824 Allocation: ThrottlingAllocationDecider should not counting relocating shards
The ThrottlingAllocationDecider is responsible to limit the number of incoming/local recoveries on a node. It therefore shouldn't count shards marked as relocating which represent the source of the recovery.

Closes #12409
2015-07-24 16:29:51 +02:00
Martijn van Groningen e997342da4 Added IndexSearcherWrapper extension point.
This extension point allows one IndexSearcherWrapper instance to intercept the searcher from the Engine before it is used for a opertion.
2015-07-24 15:52:18 +02:00
Christoph Büscher 8776463084 Merge pull request #12440 from cbuescher/feature/query-refactoring-constructorCleanup
Extended SpanFirstQueryBuilderTest
2015-07-24 15:45:39 +02:00
Christoph Büscher 1c3e8e27bf Extended SpanFirstQueryBuilderTest 2015-07-24 15:19:20 +02:00
Alex Ksikes 94d13c73c7 Refactors WildcardQueryBuilder and Parser
Relates to #10217
Closes #12110

This PR is against the query-refactoring branch.
2015-07-24 14:46:49 +02:00
Christoph Büscher 52113e7527 Merge pull request #12417 from cbuescher/remove-rangequery-context
Remove unused QueryParseContext argument in MappedFieldType#rangeQuery()
2015-07-24 14:19:53 +02:00
Adrien Grand 13d790bd4c Merge pull request #12423 from khiraiwa/patch-1
Interval time is different from the doc value.
2015-07-24 14:19:32 +02:00
Christoph Büscher 817b992511 Merge pull request #12427 from cbuescher/feature/query-refactoring-constructorCleanup
Moving null-checks from constructors to validate()
2015-07-24 14:16:54 +02:00
Martijn van Groningen c781c89e2c ShardUtils#getElasticsearchLeafReader() should use FilterLeafReader#getDelegate() instead of FilterLeafReader#unwrap
If there are multiple levels of filtered leaf readers then with the unwrap() method it immediately returns the most inner leaf reader and thus skipping of over any other filtered leaf reader that may be instance of ElasticsearchLeafReader. By using #getDelegate() method we can check each filter reader layer if it is instance of ElasticsearchLeafReader, so that we never skip over any wrapped filtered leaf reader and lose the shard id.
2015-07-24 13:49:07 +02:00
Boaz Leskes 316d1cb6c0 Core: Adapt IndicesClusterStateService to use allocation ids
Also, as set of utility methods was introduced on ShardRouting to do various types of matching with other shard routings, giving control about what exactly should be matched (same shard id, same allocation id, all but version and shard info etc.). This is useful here, but also prepares the grounds for the change needed in #12387 (making ShardRouting.equals be strict and perform exact equality).

Closes #12397
2015-07-24 13:09:47 +02:00
Alex Ksikes 7099e6ca93 Refactors ScriptQueryBuilder and Parser
Relates to #10217
Closes #12115

This PR is against the query-refactoring branch.
2015-07-24 12:16:44 +02:00
Shay Banon fc90c2affd Cancel replica recovery on another sync option copy found
When a replica is initializing from the primary, and we find a better node that has full sync id match, it is better to cancel the existing replica allocation and allocate it to the new node with sync id match (eventually)
2015-07-24 12:13:03 +02:00
Alex Ksikes 4d4dc5cceb Refactors TypeQuery
Relates to #10217
Closes #12035

This PR is against the query-refactoring branch.
2015-07-24 12:08:48 +02:00
Alex Ksikes 37c6347bce Refactors PrefixQuery
Relates to #10217
Closes #12032

This PR is against the query-refactoring branch.
2015-07-24 11:46:55 +02:00
Christoph Büscher 4df452a915 Moving null-checks from constructors to validate() 2015-07-24 11:13:39 +02:00
Alex Ksikes a4e9f642c2 Refactoring of MissingQuery
Relates to #10217
Closes #12030

This PR is against the query-refactoring branch.
2015-07-24 10:08:28 +02:00
Jay Modi f8d9de8dca Merge pull request #12419 from jaymode/fix_settings_classloader
Copy the classloader from the original settings when checking for prompts
2015-07-23 13:06:09 -04:00
jaymode 8472775477 copy the classloader from the original settings when checking for prompts
Today, when a user provides settings and specifies a classloader to be used, the classloader gets
dropped when we copy the settings to check for prompt entries. This change copies the classloader
when replacing the prompt placeholders and adds a test to ensure the InternalSettingsPreparer
always retains the classloader.

Closes #12340
2015-07-23 12:53:27 -04:00
Alex Ksikes 93674b8b1b Refactoring of RegexpQuery
Relates to #10217
Closes #11896

This PR is against the query-refactoring branch.
2015-07-23 17:40:53 +02:00
Robert Muir d1783ab11e improve plugin file some more 2015-07-23 11:37:55 -04:00
Jason Tedor 878301c795 Dump stack traces of all threads on test failure due to AssertionError
Closes #12425
2015-07-23 11:29:43 -04:00
Lee Hinman 18079168e4 Add shadow indicator when using shadow replicas 2015-07-23 09:13:54 -06:00
Christoph Büscher 026fd3843d Merge pull request #12342 from cbuescher/feature/query-refactoring-spanor
Query refactoring: SpanOrQueryBuilder and Parser
2015-07-23 17:10:39 +02:00