Commit Graph

24952 Commits

Author SHA1 Message Date
Quinn Shanahan 1bef6c7fee Update regexp-syntax.asciidoc (#20973) 2016-10-17 16:32:17 +02:00
Dimitrios Liappis b0bb72ccd7 Deprecate EOL'ed Ubuntu 15.04 from Vagrantfile
* Deprecate EOL'ed Ubuntu 15.04 from Vagrantfile

Relates pr #20921
2016-10-17 17:27:01 +03:00
Tanguy Leroux 1755cc08f3 REST API parser should fail on duplicate params/paths/methods/parts (#20940)
This commit changes the current REST API parser to make it fail and throw an exception when a REST specification file contains a duplicated parameters, or path, or method, or path part.
2016-10-17 09:19:07 +02:00
Joshua Rich 63f484ffa3 Docs: Cluster Allocation Filtering
Put more emphasis on the fact that multiple values can be specified
and move examples after explanation of settings.
2016-10-17 11:02:33 +11:00
Jason Tedor c1bdaaf80f Fix connection keep-alive header handling
This commit fixes an issue with the handling of the value "keep-alive"
on the Connection header in the Netty 4 HTTP implementation while
handling an HTTP 1.0 request. The issue was using the wrong equals
method to compare an AsciiString instance and a String instance (they
could never be equal). This commit fixes this to use the correct equals
method to compare for content equality.
2016-10-16 19:51:00 -04:00
Jason Tedor cd5777593a Fix connection close header handling
This commit fixes an issue with the handling of the value "close" on the
Connection header in the Netty 4 HTTP implementation. The issue was
using the wrong equals method to compare an AsciiString instance and a
String instance (they could never be equal). This commit fixes this to
use the correct equals method to compare for content equality.

Relates #20956
2016-10-16 13:18:09 -04:00
Clinton Gormley 8d602c6692 Updated REST test README to include required params when running tests 2016-10-16 13:25:25 +02:00
Areek Zillur e195f7dd19 Documentation for handling engine write failures 2016-10-15 15:20:38 -04:00
Areek Zillur 26f5118706 remove declaring unchecked exception due to engine write operations 2016-10-15 13:31:15 -04:00
Simon Willnauer 5137f44bd6 [TEST] return empty array if AbstractQueryTestCase#currentTypes is null
This is important to allow any test to use RandomQueryBuilder#createQuery()
since some of the query builders that are used in this test test the length
of the types array and otherwise will thow NPE if the test is not a subclass
of AbstractQueryTestCase.
2016-10-15 14:46:54 +02:00
Jason Tedor 5a03eb91e6 Add precise logging on unknown or invalid settings
Today when logging an unknown or invalid setting, the log message does
not contain the source. This means that if we are archiving such a
setting, we do not specify where the setting is from (an index, and
which index, or a persistent or transient cluster setting). This commit
provides such logging for the end user can better understand the
consequences of the unknown or invalid setting.

Relates #20951
2016-10-14 23:55:15 -04:00
Jason Tedor f23ae90d92 Fix logging configuration for AwsSdkMetrics logger
This commit fixes an issue with the configuration for the AwsSdkMetrics
logger; the issue is that the logging configuration had used underscores
instead of periods for the settings key (the perils of lenient settings
parsing).

Relates #20313
2016-10-14 23:44:39 -04:00
Areek Zillur 1bdeada8aa Generify index shard method to execute engine write operation
Now index and delete methods in index shard share code for
indexing stats. This commit collapses seperate methods for
index and delete operations into a generic execute method
for performing engine write operations. As an added benefit,
this commit cleans up the interface for indexing operation
listener making it more simple and concise to use.
2016-10-14 19:07:35 -04:00
Areek Zillur 71dc4178b9 Handle transient write failure in transport replication action 2016-10-14 18:22:10 -04:00
Areek Zillur 415fdee828 Distinguish environment failures from transient operation failures for write operations
Currently, we treat all write operation exceptions as equals, but in reality
every write operation can cause either an environment failure (i.e. a failure
that should fail the engine e.g. data corruption, lucene tragic events) or
operation failure (i.e. a failure that is transient w.r.t the operation e.g.
parsing exception).

This change bubbles up enironment failures from the engine, after failing the
engine but captures transient operation failures as part of the operation
to be processed appopriately at the transport level.
2016-10-14 16:10:26 -04:00
Areek Zillur 1b1f484c28 Distinguish primary and replica request types in TransportWriteAction 2016-10-14 16:10:26 -04:00
Christoph Büscher 289a69bf68 Use ObjectParser in ScriptSortBuilder 2016-10-14 20:19:21 +02:00
Christoph Büscher 1b78618106 Use ObjectParser in ScoreSortBuilder and FieldSortBuilder 2016-10-14 20:19:21 +02:00
Nik Everett 4fbe1a8819 CONSOLEify _cat/pending_tasks docs
Relates to #18160
2016-10-14 14:12:35 -04:00
Jun Ohtani dd4ff9b0a7 Merge pull request #20904 from johtani/remove_nullable_in_mapper_builder_context
IndexSettings should not be Null in Mapper.BuildContext
2016-10-14 23:51:20 +09:00
Jason Tedor 370253f95a Add doc note regarding processors bound
This commit expands the thread pool docs regarding the processor
setting.

Relates #20895
2016-10-14 10:32:31 -04:00
Simon Willnauer cff5993318 Parse alias filters on the coordinating node (#20916)
Today we don't parse alias filters on the coordinating node, we only forward
the alias patters to executing node and resolve it late. This has several problems
like requests that go through filtered aliases are never cached if they use date math,
since the parsing happens very late in the process even without rewriting. It also used
to be processed on every shard while we can only do it once per index on the coordinating node.
Another nice side-effect is that we are never prone to cluster-state updates that change an alias,
all nodes will execute the exact same alias filter since they are process based on the same
cluster state.
2016-10-14 16:26:09 +02:00
Jun Ohtani ddced5df1a IndexSettings should not be Null in Mapper.BuildContext
Rename method name
Change validation

Closes #20174
2016-10-14 22:01:31 +09:00
Tanguy Leroux aabbbc2202 Remove duplicate timeout parameter in Delete/Update-By-Query REST Specs (#20934)
This commit removes the duplicated "timeout" parameter introduced in #20915
2016-10-14 13:21:39 +02:00
Jason Tedor 595ec8c948 Remove artificial default processors limit
Today Elasticsearch limits the number of processors used in computing
thread counts to 32. This was from a time when Elasticsearch created
more threads than it does now and users would run into out of memory
errors. It appears the real cause of these out of memory errors was not
well understood (it's often due to ulimit settings) and so users were
left hitting these out of memory errors on boxes with high core
counts. Today Elasticsearch creates less threads (but still a lot) and
we have a bootstrap check in place to ensure that the relevant ulimit is
not too low.

There are some caveats still to having too many concurrent indexing
threads as it can lead to too many little segments, and it's not a
magical go faster knob if indexing is already bottlenecked by disk, but
this limitation is artificial and surprising to users and so it should
be removed.

This commit also increases the lower bound of the max processes ulimit,
to prepare for a world where Elasticsearch instances might be running
with more the previous cap of 32 processors. With the current settings,
Elasticsearch wants to create roughly 576 + 25 * p / 2 threads, where p
is the number of processors. Add in roughly 7 * p / 8 threads for the GC
threads and a fudge factor, and 4096 should cover us pretty well up to
256 cores.

Relates #20874
2016-10-14 05:47:26 -04:00
Simon Willnauer 7f7e99e10b [TEST] Add basic tests for ExplainRequest and ShardValidationQueryRequest 2016-10-14 10:06:38 +02:00
Tanguy Leroux f5e1c6d330 Update Delete/Update-By-Query REST Specs (#20915)
This commit removes unused parameters from the Update-By-Query and Delete-By-Query REST specification files.
2016-10-14 09:26:33 +02:00
Nik Everett 68ed183381 CONSOLEify a few more _cat docs
`_cat/master`, `_cat/nodeattrs`, `_cat/nodes`.
2016-10-13 16:43:06 -04:00
Simon Willnauer b2c8da25fd Remove unreleased version constant
Some people apparently never run tests when they change this file.
Neither do they read comments right below the line they change that
they should do the change after all.
2016-10-13 22:13:18 +02:00
Clinton Gormley e739ecf67c Fix version constant for 5.0.0 2016-10-13 20:42:43 +02:00
Clinton Gormley feefb71007 Renamed v5.0.0-rc2 to 5.0.0 2016-10-13 20:21:49 +02:00
Nik Everett 279baa0284 Add a flush to test in _cat/indices.asciidoc
We test that sorting by `store.size` works but sometimes the
sizes aren't what we expect. At least in CI:
https://elasticsearch-ci.elastic.co/job/elastic+elasticsearch+master+multijob-unix-compatibility/os=opensuse/101/console
https://elasticsearch-ci.elastic.co/job/elastic+elasticsearch+5.x+multijob-unix-compatibility/os=centos/100/console

I haven't been able to reproduce it locally but adding a `_flush`
won't hurt and might make the inconsistency vanish.
2016-10-13 13:21:57 -04:00
kunal642 e20d9d6478 Removed unnecessary assertion on boolean values (#20910)
* Removed unnecessary assertion on boolean values

* Reversed changes for false assertion

* corrected formatting

* reverted changes for SettingsUpdater
2016-10-13 12:12:57 -04:00
Simon Willnauer 7e5d8a6e5a [TEST] use a different node ID for the test nodes 2016-10-13 17:39:19 +02:00
Nik Everett 3bba7dbe07 Docs: note about snapshot version compatibility (#20896)
It is important that folks understand that snapshot/restore isn't
for archiving. It is appropriate for backup and disaster recovery
but not for archival over long periods of time because of version
incompatibility.

Closes #20866
2016-10-13 10:49:32 -04:00
Tanguy Leroux e71c30c71d Mustache: Add {{#url}}{{/url}} function to URL encode strings (#20838)
This commit adds a new Mustache function (codename: url) and a new URLEncoder that can be used to URL encode strings in mustache templates.
2016-10-13 16:17:28 +02:00
Simon Willnauer 61fd1cd582 Make AbstractSearchAsyncAction more testable and add a basic test case (#20890)
`AbstractSearchAsyncAction` has only been tested in integration tests.
The infrastructure is rather critical and should be tested on a unit-test
level. This change takes the first step.
2016-10-13 16:07:31 +02:00
Jay Modi fdceb64072 Use TimveValue instead of long for CacheBuilder methods
This changes the CacheBuilder methods that are used to set expiration times to accept a
TimeValue instead of long. Accepting a long can lead to issues where the incorrect value is
passed in as the time unit is not clearly identified. By using TimeValue the caller no longer
needs to worry about the time unit used by the cache or builder.
2016-10-13 09:27:31 -04:00
Uli Fahrer 85094d9190 Fix wrong heading
Relates #20906
2016-10-13 07:06:53 -04:00
Clinton Gormley 101ea0549a Add note about retention periods to reindex-upgrade docs 2016-10-13 12:13:55 +02:00
Simon Willnauer 43d11600ab [TEST] Add test that shows how to use a classic pull-parser with the object parser 2016-10-13 11:47:17 +02:00
Jun Ohtani 75c9e4f418 IndexSettings should not be Null in Mapper.BuildContext
Remove Nullable notation
Add unit test

Closes #20174
2016-10-13 18:11:08 +09:00
Simon Willnauer ce1a9a2b06 [TEST] Add test that filtered alias with date math isn't cached by the request cache 2016-10-13 10:18:40 +02:00
Clinton Gormley 389d365697 Fix YAML formatting in several REST tests 2016-10-13 09:58:25 +02:00
Colin Goodheart-Smithe 71aa807acd Fixes MultiMatchQuery so that it doesn't provide a null context (#20882)
Before this change the `MultiMatchQuery` called the field types
`termQuery()` with a null context. This is not correct so this change
fixes this so the `MultiMatchQuery` now uses the `ShardQueryContext` it
stores as a field.

Relates to https://github.com/elastic/elasticsearch/pull/20796#pullrequestreview-3606305
2016-10-13 08:44:41 +01:00
Thibaud BARDIN 1bcd26627c [DOCS] Fix typo in "Wait For Active Shards" part (#20900)
Add missing closing backtick
2016-10-13 08:53:30 +02:00
Simon Willnauer 12392b5425 Ensure port range is readable in the exception message (#20893)
Both netty3 and netty4 http implementation printed the default
toString representation of PortRange if ports couldn't be bound.
This commit adds a better default toString method to PortRange and
uses the string representation for the error message in the http
implementations.
2016-10-12 22:33:47 +02:00
Simon Willnauer 968fbaceef Never use ThreadPool#estimatedTimeInMillis as wall-clock time replacement 2016-10-12 22:13:13 +02:00
Areek Zillur 133be6631d Merge branch 'master' into cleanup/transport_bulk 2016-10-12 13:09:29 -04:00
Yannick Welsch 3d3ed7a83a Increase number of allowed failures in MockRepository for snapshot restore test
The test testDataFileCorruptionDuringRestore expects failures to happen when accessing snapshot data. It would sometimes
fail however as MockRepository (by default) only simulates 100 failures.
2016-10-12 19:03:49 +02:00