Commit Graph

20683 Commits

Author SHA1 Message Date
Isabel Drost-Fromm 02e698bc43 Third round of comments 2016-03-14 14:02:22 +01:00
Isabel Drost-Fromm 720f47e87f Second round of comments 2016-03-14 14:02:22 +01:00
Isabel Drost-Fromm dd6e835e30 First comments. 2016-03-14 14:02:22 +01:00
Isabel Drost-Fromm 5bff6e4218 Refactor FieldSortBuilder
* adds json parsing,
* refactors json serialisation,
* adds writable parsing and serialisation,
* adds json and writable roundtrip test
2016-03-14 14:02:22 +01:00
Clinton Gormley 0ed0fea558 Updated link to Joda time zones 2016-03-14 12:24:58 +01:00
Christoph Büscher f0074668db Merge branch 'master' into sort-serialization-scriptsort 2016-03-14 12:15:53 +01:00
Simon Willnauer a69d44ce5c Merge pull request #17048 from s1monw/use_concrete_index_on_clusterstate_update
Resolve index names to Index instances early

Today index names are often resolved lazily, only when they are really
needed. This can be problematic especially when it gets to mapping updates
etc. when a node sends a mapping update to the master but while the request
is in-flight the index changes for whatever reason we would still apply the update
since we use the name of the index to identify the index in the clusterstate.
The problem is that index names can be reused which happens in practice and sometimes
even in a automated way rendering this problem as realistic.
In this change we resolve the index including it's UUID as early as possible in places
where changes to the clusterstate are possible. For instance mapping updates on a node use a
concrete index rather than it's name and the master will fail the mapping update iff
the index can't be found by it's <name, uuid> tuple.

Closes #17048
2016-03-14 11:40:22 +01:00
Christoph Büscher 97638c95fc Merge branch 'master' into feature-suggest-refactoring
Conflicts:
	docs/reference/migration/migrate_5_0.asciidoc
2016-03-14 11:13:47 +01:00
Simon Willnauer 31740e279f Resolve index names to Index instances early
Today index names are often resolved lazily, only when they are really
needed. This can be problematic especially when it gets to mapping updates
etc. when a node sends a mapping update to the master but while the request
is in-flight the index changes for whatever reason we would still apply the update
since we use the name of the index to identify the index in the clusterstate.
The problem is that index names can be reused which happens in practice and sometimes
even in a automated way rendering this problem as realistic.
In this change we resolve the index including it's UUID as early as possible in places
where changes to the clusterstate are possible. For instance mapping updates on a node use a
concrete index rather than it's name and the master will fail the mapping update iff
the index can't be found by it's <name, uuid> tuple.

Closes #17048
2016-03-14 11:08:48 +01:00
Clinton Gormley c3cd8564df Corrected regexp syntax docs for COMPLEMENT 2016-03-14 10:46:31 +01:00
Alexander Kazakov 8e6b2b3909 Check that _value is used in aggregations script before setting value to specialValue #14262 2016-03-14 12:04:06 +03:00
Clinton Gormley c90b4f3bae Docs: Added note about upgrading from 1.x to 5.x 2016-03-14 09:58:46 +01:00
Adrien Grand 071b396306 Fix test bug: norms are on by default on _all. 2016-03-14 09:06:11 +01:00
Adrien Grand c50c5a52d5 Rework norms parameters for 5.0. #16987
Changes:
 - no more option to configure eager/lazy loading of the norms (useless now
   that orms are disk-based)
 - only the `string`, `text` and `keyword` fields support the `norms` setting
 - the `norms` setting takes a boolean that decides whether norms should be
   stored in the index but old options are still supported to give users time
   to upgrade
 - setting a `boost` no longer implicitely enables norms (for new indices only,
   this is still needed for old indices)
2016-03-14 08:42:35 +01:00
Adrien Grand 5596e31068 Upgrade to lucene-6.0.0-f0aa4fc. #17075 2016-03-14 07:58:52 +01:00
Jason Tedor 8a05c2a2be Bootstrap does not set system properties
Today, certain bootstrap properties are set and read via system
properties. This action-at-distance way of managing these properties is
rather confusing, and completely unnecessary. But another problem exists
with setting these as system properties. Namely, these system properties
are interpreted as Elasticsearch settings, not all of which are
registered. This leads to Elasticsearch failing to startup if any of
these special properties are set. Instead, these properties should be
kept as local as possible, and passed around as method parameters where
needed. This eliminates the action-at-distance way of handling these
properties, and eliminates the need to register these non-setting
properties. This commit does exactly that.

Additionally, today we use the "-D" command line flag to set the
properties, but this is confusing because "-D" is a special flag to the
JVM for setting system properties. This creates confusion because some
"-D" properties should be passed via arguments to the JVM (so via
ES_JAVA_OPTS), and some should be passed as arguments to
Elasticsearch. This commit changes the "-D" flag for Elasticsearch
settings to "-E".
2016-03-13 20:09:15 -04:00
Jason Tedor 8ac5a98b87 Remove links to nonexistent migration docs 2016-03-13 19:12:06 -04:00
Jason Tedor 4353b2e024 Do not pass double-dash arguments on startup
This commit addresses an issue in the init scripts which are passing
invalid command line arguments to the startup script.

Closes #17087
2016-03-13 18:58:08 -04:00
Boaz Leskes e472d7894b Log suppressed stack traces under DEBUG
To make API's output more easy to read we are suppressing stack traces (#12991) unless explicitly requested by setting `error_trace=true` on the request. To compensate we are logging the stacktrace into the logs so people can look it up even the error_trace wasn't enabled. Currently we do so using the `INFO` level which can be verbose if an api is called repeatedly by some automation.  For example, if someone tries to read from an index that doesn't exist we will respond with a 404 exception and log under info every time. We should reduce the level to `DEBUG` as we do with other API driven errors. Internal errors (rest codes >=500) are logged as WARN.

Closes #16627
2016-03-13 21:50:17 +01:00
Clinton Gormley 5f48b9c86a Removed breaking changes docs for < 5.0 2016-03-13 21:18:44 +01:00
Clinton Gormley 5c845f8bb5 Reworked 5.0 breaking changes docs 2016-03-13 21:17:48 +01:00
David Pilato 25531b7299 Update after last review
We check for null. Test added as well.
2016-03-13 15:36:17 +01:00
David Pilato e9e1e25998 Fix after merge with master 2016-03-13 15:14:07 +01:00
David Pilato 9acb0bb28c Merge branch 'master' into pr/16598-register-filter-settings
# Conflicts:
#	core/src/main/java/org/elasticsearch/cluster/service/InternalClusterService.java
#	core/src/main/java/org/elasticsearch/common/settings/IndexScopedSettings.java
#	core/src/main/java/org/elasticsearch/common/settings/Setting.java
2016-03-13 14:52:10 +01:00
Yannick Welsch 625695a92a [TEST] MockRepository should also unblock repositories that are not blocked yet 2016-03-13 14:12:29 +01:00
Simon Willnauer 121e7c8ca4 Add infrastructure to run REST tests on a multi-version cluster
This change adds the infrastructure to run the rest tests on a multi-node
cluster that users 2 different minor versions of elasticsearch. It doesn't implement
any dedicated BWC tests but rather leverages the existing REST tests.

Since we don't have a real version to test against, the tests uses the current version
until the first minor / RC is released to ensure the infrastructure works.

Relates to #14406
Closes #17072
2016-03-13 10:52:39 +01:00
Simon Willnauer 22ee910f43 Merge pull request #17078 from s1monw/use_seednode_in_gradle
Use a seed node to form multi-node cluster in integ tests
2016-03-13 10:11:18 +01:00
Clinton Gormley b1cf2b2cb3 Moved CONTRIBUTING.md back to the root directory
The CONTRIBUTING.md file can be in the root directory or
in the .github directory and will still be used for
the contributing guidelines on Github.

Moved back to the root directory so that it is more
visible outside Github
2016-03-12 14:58:30 +01:00
Ryan Ernst 93f1a56168 Merge pull request #16361 from rjernst/normalize_plugin_zip
Enforce plugin zip does not contain zip entries outside of the plugin dir
2016-03-11 14:54:45 -08:00
Ryan Ernst 8b26c260d1 Plugins: Enforce plugin zip does not contain zip entries outside of the unzip dir
When unzipping a plugin zip, the zip entries are resolved relative to
the directory being unzipped into. However, there are currently no
checks that the entry name was not absolute, or relatively points
outside of the plugin dir. This change adds a check for those two cases.
2016-03-11 14:53:14 -08:00
Areek Zillur 4b803d75cf nuke SuggestParseElement 2016-03-11 16:27:33 -05:00
Ryan Ernst 5f3d0067f8 Merge pull request #17024 from rjernst/cli-parsing
Cli: Switch to jopt-simple
2016-03-11 12:35:39 -08:00
Areek Zillur 97e2bab4cd clarify parsing logic in SuggestBuilder 2016-03-11 15:06:42 -05:00
Areek Zillur c9f30f2f3f scope internal methods in suggest builders 2016-03-11 15:06:36 -05:00
Ryan Ernst 3f44e1d429 Remove old reference to site plugins example in docs 2016-03-11 11:53:20 -08:00
Ryan Ernst 5bd7da5659 Addressed PR feedback
* Fix tests still referring to -E
* add comment about missing classes
* rename writer constant
2016-03-11 11:46:23 -08:00
Yannick Welsch afb54bab44 [TEST] Wait on all data nodes to be blocked if blocks active
Fixes race condition in MockRepository where unblock happens before block
2016-03-11 20:20:07 +01:00
Ryan Ernst 591fb8f028 Merge branch 'master' into cli-parsing 2016-03-11 10:45:05 -08:00
Simon Willnauer e91245e25f Use a seed node to form multi-node cluster in integ tests
Today we use hardcoded ports to form a cluster in the mulit-node case.
The hardcoded URIs are passed to the unicast host list which is error prone and
might cause problems if those ports are exhausted etc. This commit moves to a
less error prone way of forming the cluster where all nodes are started with port `0`
and all but the first node wait for the first node to write it's ports file to form a
cluster. This seed node is enough to form a cluster.
2016-03-11 19:20:37 +01:00
Ali Beyad 31dcb3e18b Merge pull request #16873 from abeyad/suggester-wiring-refactoring
Change internal representation of suggesters
2016-03-11 12:34:35 -05:00
Ali Beyad 4c1366bb21 Merge pull request #1 from cbuescher/pr/16873
Fixing some tests and compile problems in reindex module
2016-03-11 12:02:22 -05:00
Christoph Büscher bbcbba1bf5 Fixing some tests and compile problems in reindex module 2016-03-11 17:58:13 +01:00
Christoph Büscher 5107388fe9 Added enum for script sort type 2016-03-11 17:32:39 +01:00
Christoph Büscher 8ab4d001e2 Make ScriptSortBuilder implement NamedWritable
This adds methods and tests to ScriptSortBuilder that
makes it implement NamedWritable and adds the fromXContent
method needed to read itseld from xContent.
2016-03-11 16:57:22 +01:00
Yannick Welsch 422df6089c [TEST] Unblock nodes if snapshot/restore test fails 2016-03-11 16:38:52 +01:00
Christoph Büscher 7aa29e3f7c Make Copy of collate parameter map
Test failures showed problems with passing down
the same collate parameter map reference from the
phrase suggestion builder to the context where.
This changes the collate parameter setters to
make a shallow copy of the map passed in.
2016-03-11 15:20:52 +01:00
Clinton Gormley a5a9bbfe88 Update compound-word-tokenfilter.asciidoc
Only FOP v1.2 compatible hyphenation files are supported by the hyphenation decompounder
2016-03-11 15:08:36 +01:00
Jason Tedor f465d98eb3 Add raw recovery progress to cat recovery API
This commit adds fields bytes_recovered and files_recovered to the cat
recovery API. These fields, respectively, indicate the total number of
bytes and files recovered. Additionally, for consistency, some totals
fields and translog recovery fields have been renamed.

Closes #17064
2016-03-11 08:27:09 -05:00
Christoph Büscher daeffb149c Merge branch 'master' into feature-suggest-refactoring 2016-03-11 10:37:28 +01:00
Yannick Welsch a7e78c91ed Merge pull request #16707 from ywelsch/enhance/elasticsearch-proper-logging-usage
Statically check that number of placeholders in log message matches number of parameters
2016-03-11 10:33:45 +01:00