Commit Graph

20945 Commits

Author SHA1 Message Date
Clinton Gormley 30d78f4be0 In cat.snapshots, repository is required
Closes #17216
2016-03-25 14:23:52 +01:00
Tanguy Leroux 2c00843683 Merge pull request #17345 from tlrx/do-not-retrieve-all-stats
Do not retrieve all indices stats when checking for cache resets
2016-03-25 13:38:12 +01:00
Tanguy Leroux a22529cceb Do not retrieve all indices stats when checking for cache resets 2016-03-25 13:16:12 +01:00
Boaz Leskes b8227a7222 Enforce `discovery.zen.minimum_master_nodes` is set when bound to a public ip #17288
discovery.zen.minimum_master_nodes is the single most important setting to set on a production cluster. We have no way of supplying a good default so it must be set by the user. Binding a node to a public IP (as opposed to the default local host) is a good enough indication that a node will be part of a production cluster cluster and thus it's a good tradeoff to enforce the settings. Note that nothing prevent users from setting it to 1 in a single node cluster.

Closes #17288
2016-03-25 12:56:20 +01:00
Boaz Leskes fe43eef1b5 Port Primary Terms to master #17044
Primary terms is a way to make sure that operations replicated from stale primary are rejected by shards following a newly elected primary.

Original PRs adding this to the seq# feature branch #14062 , #14651 . Unlike those PR, here we take a different approach (based on newer code in master) where the primary terms are stored in the meta data only (and not in `ShardRouting` objects).

Relates to #17038

Closes #17044
2016-03-25 12:01:00 +01:00
javanna 7bc4a35f9a adapt ZenDiscoveryUnitTests to removal of INGEST_ATTR, MASTER_ATTR and DATA_ATTR 2016-03-25 10:47:02 +01:00
Jason Tedor 85b06f48cf Revert "Add debug logging for Vagrant upgrade test"
This reverts commit 7ecfa6e2ad.
2016-03-24 21:59:32 -04:00
Jason Tedor a0634b2442 Merge pull request #17197 from jasontedor/chown
Elasticsearch ownership for data, logs, and configs
2016-03-24 21:21:11 -04:00
Jason Tedor d22b5977de Ownership for data, logs, and configs for packages
This commit ensures that the data, logs, and config directories have the
proper ownership after the packages are installed. Additionally, this
commit ensures that the configs in /etc/elasticsearch are preserved
after removal of the RPM package.
2016-03-24 20:56:02 -04:00
Tal Levy 7f812f5990 Merge pull request #16562 from talevy/ingest_verbose_error_metdata
add on_failure exception metadata to ingest document for verbose simulate
2016-03-24 16:22:24 -07:00
Tal Levy cabc4b1636 add on_failure exception metadata to ingest document for verbose simulate 2016-03-24 16:11:47 -07:00
Dan Jasek e366a45203 Add created flag to IndexingOperationListener#postIndex
fixes #17333
2016-03-24 16:50:13 -06:00
Jason Tedor 7f0134e725 Revert "Merge pull request #16843 from xuzha/s3-encryption"
This reverts commit 37a183d9ed, reversing
changes made to 08903f1ed8.
2016-03-24 17:11:02 -04:00
Xu Zhang 37a183d9ed Merge pull request #16843 from xuzha/s3-encryption
S3 client side encryption
2016-03-24 12:58:40 -07:00
Xu Zhang 38923b89c2 Update Format, add new settings into the setting test 2016-03-24 12:16:57 -07:00
Xu Zhang 7499e3aa4a Update and rebase the init implementation.
Also removes the MD5 checks from our side, AWS S3 SDK java is doing the
check.
2016-03-24 11:21:40 -07:00
Nicolas Trésegnie ea78fd6560 Add client-side encryption
The Java Cryptography Extension (JCE) has to be installed to use this feature.
2016-03-24 11:13:37 -07:00
Clinton Gormley 08903f1ed8 Tidied the Painless docs and added the experimental tag 2016-03-24 18:34:40 +01:00
javanna dd32bcea7a remove needless settings from transport client 2016-03-24 18:21:40 +01:00
javanna d2931b97e9 adapt to upstream changes 2016-03-24 18:18:27 +01:00
javanna 27d4994aff Merge branch 'master' into enhancement/remove_node_client_setting 2016-03-24 18:10:11 +01:00
Nik Everett 584ba6133d Remove PROTOTYPE from RescorerBuilders
This changes the serialization order for QueryRescorerBuilder's but
that is ok because 5.0.0 doesn't need to be wire compatible with anything.
2016-03-24 13:04:37 -04:00
Nik Everett 5e8656aff0 Throw an exception if Writeable.Reader reads null
If a Writeable.Reader returns null it is always a bug, probably one that
will cause corruption in the StreamInput it was trying to read from. This
commit adds a check that attempts to catch these errors quickly including
the name of the reader.
2016-03-24 13:02:22 -04:00
Boaz Leskes 6dd164d0bd Include pings from client nodes in master election
We currently have a `discovery.zen.master_election.filter_client` setting that control whether their ping responses are ignored for master election (which is the current default). With the push to treat client nodes as normal nodes (and promote the transport/rest clients for client work), this should be changed. This commit remove this setting and it's companion `discovery.zen.master_election.filter_data` setting (currently defaulting to  false) in favor of singe `discovery.zen.master_election.ignore_non_master_pings` setting with more intuitive name (defaulting to false).

Resolves #17325
Closes #17329
2016-03-24 17:48:05 +01:00
Simon Willnauer d0413f0f0e Merge pull request #17327 from s1monw/harden_test
Improve test to not rely on thread slowness

We have to swap the second latch before we count it down otherwise
threads might be faster than the test. This has happend on a recent
CI failure: https://elasticsearch-ci.elastic.co/job/elastic+elasticsearch+master+multijob-os-compatibility/os=ubuntu/121/console

This commit also adds a synchronized on the close method since it's
canceling and modifying a member varialbe that is assigned under lock.
2016-03-24 16:51:48 +01:00
Clinton Gormley 0e7054cf02 Merge pull request #17272 from pengqiuyuan/master
Update template-query.asciidoc
2016-03-24 16:49:49 +01:00
Simon Willnauer f81fb89ea5 simplify test to not use lambda at all 2016-03-24 16:48:50 +01:00
Simon Willnauer 49d868b491 Improve test to not rely on thread slowness
We have to swap the second latch before we count it down otherwise
threads might be faster than the test. This has happend on a recent
CI failure: https://elasticsearch-ci.elastic.co/job/elastic+elasticsearch+master+multijob-os-compatibility/os=ubuntu/121/console

This commit also adds a synchronized on the close method since it's
canceling and modifying a member varialbe that is assigned under lock.
2016-03-24 16:30:34 +01:00
Nik Everett 93ab4cfc99 Stop using PROTOTYPE in NamedWriteableRegistry
readFrom is confusing because it requires an instance of the type that it
is reading but it doesn't modify it. But we also have (deprecated) methods
named readFrom that *do* modify the instance. The "right" way to implement
the non-modifying readFrom is to delegate to a constructor that takes a
StreamInput so that the read object can be immutable. Now that we have
`@FunctionalInterface`s it is fairly easy to register things by referring
directly to the constructor.

This change modifying NamedWriteableRegistry so that it does that. It keeps
supporting `registerPrototype` which registers objects to be read by
readFrom but deprecates it and delegates it to a new `register` method
that allows passing a simple functional interface. It also cuts Task.Status
subclasses over to using that method.

The start of #17085
2016-03-24 11:26:44 -04:00
Luca Cavanna 609456a324 Merge pull request #17278 from javanna/fix/remove_cluster_stats_os_mem
Cluster Stats: remove mem section
2016-03-24 15:59:05 +01:00
Isabel Drost-Fromm 5dd481bfe3 Disallow reverse option and check it throws an exception
This adds tests to check that using reverse as sort option is disallowed
and throws an exception.
2016-03-24 15:55:21 +01:00
javanna ce86fc5647 Cluster Stats: remove mem section
The available memory metric was always set to `0` since 2.0.beta1 (bug).  was left behind but never set. Turns out the section wasn't that useful, as it would only output the total memory available throughout all nodes in the cluster. We decided to remove the section then.
2016-03-24 15:49:27 +01:00
Jason Tedor 4b17a5c73f Merge pull request #17324 from jasontedor/settings-cleanup
Settings loader cleanup
2016-03-24 10:44:12 -04:00
javanna 2c6e78e16c more Writeable in ClusterStatsNodes 2016-03-24 15:28:10 +01:00
Simon Willnauer 6ede670524 Merge pull request #17206 from tlhunter/patch-1
Gender neutral README

Reduce confusion in situations where a twitter user isn't a man
2016-03-24 15:25:57 +01:00
Jason Tedor f522fa1df3 Settings loader local variables can be final 2016-03-24 10:25:46 -04:00
javanna 82014ebec3 use read/writeOptionalWriteable 2016-03-24 15:22:31 +01:00
javanna 06fd61fb00 make roles final 2016-03-24 15:20:50 +01:00
javanna 2ea694b4bc renaming of discovery.zen.master_election.filter_client setting will be a follow-up, make it a TODO, opened #17325 2016-03-24 15:20:02 +01:00
Jason Tedor ad5438a6a9 Use expectThrows in YamlSettingsLoaderTests
This commit refactors the unit tests in YamlSettingsLoaderTests to use
exceptThrows for simplification.
2016-03-24 10:14:04 -04:00
Jason Tedor 84a308db80 Fix line-length issues in YamlSettingsLoaderTests
This commit fixes a line-length checkstyle violation in
YamlSettingsLoaderTests.java and removes this file from the checkstyle
line-length suppressions.
2016-03-24 10:14:04 -04:00
Jason Tedor f9500b1d6a Use expectThrows in JsonSettingsLoaderTests
This commit refactors the unit tests in JsonSettingsLoaderTests to use
exceptThrows for simplification.
2016-03-24 10:14:03 -04:00
Jason Tedor 7841b439ec Fix line-length issue in JsonSettingsLoaderTests
This commit fixes a line-length checkstyle violation in
JsonSettingsLoaderTests.java and removes this file from the checkstyle
line-length suppressions.
2016-03-24 10:14:03 -04:00
javanna df2923ced4 roles to become unmodifiableSet 2016-03-24 15:11:51 +01:00
javanna cd05cf91f0 remove PROTOTYPE from DiscoveryNode 2016-03-24 15:09:47 +01:00
Nik Everett 48aaebf23d [reindex] Wait for headers
The test was checking that we'd set the headers properly but in some cases
the request had yet to come in because it was running on another thread.
Now we wait for the headers to show up before failing the test.

Closes #17299
2016-03-24 09:55:49 -04:00
Jason Tedor ca5e48d39a Test that NoDuplicatesProperties throws for null value
This commit adds a test that NoDuplicatesProperties throws a
NullPointerException if an attempt is made to put a key that corresponds
to a null value. This behavior ultimately comes from the super class
Properties but the test ensures that we retain this behavior.
2016-03-24 09:47:01 -04:00
Jason Tedor cf92151513 Fix line-length issue in PropertiesSettingsLoader
This commit fixes a line-length checkstyle violation in
PropertiesSettingsLoader.java and removes this file from the checkstyle
line-length suppressions.
2016-03-24 09:47:01 -04:00
Jason Tedor c0fa00a2fd Use expectThrows in PropertiesSettingsLoaderTests
This commit refactors the unit tests in PropertiesSettingsLoaderTests to
use exceptThrows for simplification.
2016-03-24 09:47:01 -04:00
Jason Tedor 7323c37339 Refactor PropertiesSettingsLoader
This commit refactors PropertiesSettingsLoader to remove some duplicate
code.
2016-03-24 09:44:21 -04:00