Commit Graph

137 Commits

Author SHA1 Message Date
Nik Everett 4d89aa97e9 Vagrant tests should use plugin zips
Fixes failing packaging tests:
https://elasticsearch-ci.elastic.co/job/elastic+elasticsearch+master+packaging-tests/1049/console
2016-07-21 10:02:51 -04:00
Nik Everett f084469c27 Fix syntax for template tests 2016-07-13 11:34:06 -04:00
Nik Everett e9d292b450 Fix names of tar tests 2016-07-13 11:33:55 -04:00
Jason Tedor 68676f8cf1 Migrate Vagrant tests for Fedora to Fedora 24
This commit migrates the Vagrant box for Fedora for the packaging tests
from Fedora 22 to Fedora 24 as Fedora 22 reached end-of-line upon the
release of Fedora 24.

Relates #19308
2016-07-07 13:31:30 -04:00
Jason Tedor a20cf8275b Add version 2.3.4 to upgrade from versions 2016-07-07 12:43:20 -04:00
Jason Tedor a13717633c Fix typo in name of remove ingest-user-agent test
This commit fixes a simple typo in the name of the test for testing the
removal of the ingest-user-agent plugin.
2016-07-07 09:09:11 -04:00
Martijn van Groningen b4defafcb2 ingest: Renamed from `ingest-useragent` to `ingest-user-agent` and processor from `useragent` to `user_agent`
and on some other places did similar renaming. This is consistent with ES naming. Also made sure that the docs are navigable from the reference guide.
2016-07-07 09:43:43 +02:00
Nik Everett b66fc308fc Add ingest-useragent to vagrant tests 2016-07-01 11:29:48 -04:00
Jason Tedor a24d302e73 Fix discovery-azure-classic plugin packaging test
This commit fixes the discovery-azure-classing packaging test by fixing
the expected name of the installed plugin.
2016-06-30 14:47:38 -04:00
David Pilato 527a9c7f48 Deprecate discovery-azure and rename it to discovery-azure-classic
As discussed at https://github.com/elastic/elasticsearch-cloud-azure/issues/91#issuecomment-229113595, we know that the current `discovery-azure` plugin only works with Azure Classic VMs / Services (which is somehow Legacy now).

The proposal here is to rename `discovery-azure` to `discovery-azure-classic` in case some users are using it.
And deprecate it for 5.0.

Closes #19144.
2016-06-30 14:42:40 +02:00
Alexander Reelsen 8b43480b94 Tests: Fix vagrant tests to ignore progress bar in assertions 2016-06-30 09:08:41 +02:00
Britta Weber b2da5424b4 [TEST] fix vagrant tests for seed with format ABC:DEF (#19157)
* [TEST] fix vagrant tests for seed with format ABC:DEF

Otherwise one gets an error message when passing
-Dtests.seed=ABC:DEF
to any test run.
2016-06-29 20:18:25 +02:00
Jason Tedor ef89e564f4 Update Vagrant boxes before running packaging test
This commit adds an execution of a Vagrant box update task before
bringing a Vagrant box up for running packaging tests.

Relates #19155
2016-06-29 11:04:54 -04:00
Nik Everett eb67b3c613 Move the build vagrant build listener
That way it doesn't register until we actually try and set up
the vagrant test root. We don't need it all the time.
2016-06-27 14:39:33 -04:00
Jason Tedor 3f5b9943fd Randomize packaging upgrade test
This commit adds randomization for the packaging upgrade test. In
particular, we extract a list of the released version of Elasticsearch
from Maven Central and randomize the selection of the version to upgrade
from. The randomization is repeatable, and supports the tests.seed
property. Specific versions can be tested by setting the property
tests.packaging.upgrade.from.versions.

Relates #19033
2016-06-27 12:13:06 -04:00
Jason Tedor 5e960c0d03 Move upgrade test to upgrade from version 2.3.3
This commit moves the upgrade test to test upgrading from version 2.3.3
instead of from version 2.0.0.

Relates #19029
2016-06-22 13:27:19 -04:00
Jason Tedor 30b8a51eb9 Fix lang-painless packaging test
This commit fixes a failing lang-painless packaging test after a change
to the dependencies was made in commit
0bfb166eeb.
2016-06-13 10:37:21 -04:00
Nik Everett 06d26635de Packaging tests: ingest-grok is now ingest-common 2016-06-08 14:03:48 -04:00
Jason Tedor f16f65741e Fix when plugins directory is symlink
This commit fixes an issue with the plugins directory being a symbolic
link. Namely, the install plugins command attempts to always create the
plugins directory just in case it does not exist. The JDK method used
here guarantees that the directory is created, and an exception is not
thrown if the directory could not be created because it already
exists. The problem is that this JDK method does not respect symlinks so
its internal existence checks fails, it proceeds to attempt to create
the directory, but the directory creation fails because the symlink
exists. This is documented as being not an issue. We work around this by
checking if there is a symlink where we expect the plugins directory to
be, and only attempt to create if not. We add a unit test that plugin
installation to a symlinked plugins directory works as expected.
2016-05-26 14:10:32 -04:00
Jason Tedor d29844e597 Remove custom plugins path
This commit removes the ability to specify a custom plugins
path. Instead, the plugins path will always be a subdirectory called
"plugins" off of the home directory.
2016-05-26 10:16:25 -04:00
Jason Tedor 84dfa360b1 Fix list of poi dependencies for ingest-attachment
This commit fixes the list of poi dependencies for the ingest-attachment
plugin after they were upgraded in
1d40c4bbc1.
2016-05-24 17:03:25 -04:00
Tanguy Leroux 1f011f9dea Remove Delete-By-Query plugin
closes #18469
2016-05-24 13:28:20 +02:00
Jason Tedor c257e2c51f Remove settings and system properties entanglement
Today when parsing settings during bootstrap, we add a system property
for every Elasticsearch setting. Additionally, settings can be set via
system properties. This commit simplifies this situation.
 - settings are no longer propogated to system properties
 - system properties can not be used to set settings
 - the "es." prefix on settings is no longer required (nor permitted)
 - test logging has a dedicated system property (tests.logger.level)

Relates #18198
2016-05-19 14:08:08 -04:00
Tanguy Leroux 35d3bdab84 Add Google Cloud Storage repository plugin
Closes #12880
2016-05-19 13:26:23 +02:00
Jason Tedor db4809d906 Remove last vestigates of /bin/sh shebangs
This commit removes the remaining /bin/sh shebangs in favor of
/bin/bash.

Relates #18448
2016-05-18 11:03:00 -04:00
Lee Hinman ff5c7965ed Don't run `mkdir` when $DATA_DIR contains a comma-separated list
Resolves #16992
Resolves https://github.com/elastic/cookbook-elasticsearch/issues/441
2016-05-17 13:42:24 -06:00
Jason Tedor 9ce96f5792 Add tests that packages depend on bash
This commit adds bats tests that the RPM and Debian packages depend on
bash.

Relates #18292
2016-05-12 09:04:24 -04:00
Jason Tedor 7d1fd17172 Remove plugin script parsing of system properties
The plugin script parses command-line options looking for Java system
properties and extracts these arguments to pass to the java command when
starting the JVM. Since elasticsearch-plugin allows arbitrary user
arguments to the JVM via ES_JAVA_OPTS, this parsing is unnecessary. This
commit removes this unnecessary 

Relates #18207
2016-05-09 13:06:18 -04:00
Jason Tedor 3f3fa59406 Account for rpm behavior difference on directories
This commit modifies the packaging tests to account for the fact that
rpm behaves differently with respect to preserving directories marked as
"CONFIG | NOREPLACE" on older versions versus newer versions. Older
versions will leave the directory as-is while newer versions will append
the suffix ".rpmsave" to the directory name.

Relates #18216
2016-05-09 12:25:52 -04:00
Jason Tedor 0eaa831f48 Preserve config files from RPM install
This commit modifies the packaging for the RPM package so that edits to
config files will not get lost during removal and upgrade.

Relates #18188
2016-05-06 13:24:54 -04:00
Ryan Ernst 8fc51380de Tests: improve logging for vagrant to emit entire output on failure
This change makes the vagrant tasks extend LoggedExec, so that the
entire vagrant output can be dumped on failure (and completely logged
when using --info). It should help for debugging issues like #18122.
2016-05-04 17:29:23 -07:00
Jason Tedor 4c6cf7ee88 Pass ES_JAVA_OPTS to JVM for plugins script
This commit adds support for ES_JAVA_OPTS to the elasticsearch-plugin
script.

Relates #18140
2016-05-04 12:48:39 -04:00
Lee Hinman 9da88a99da Fix exit code
Exit with proper exit code (1) and an error message if elasticsearch
executable binary does not exists or has insufficient permissions to
execute.

Squashed commit of the following:

commit 9768d316303418ba4f9c96d3f87c376048a1b1bc
Author: Puru <tuladharpuru@gmail.com>
Date:   Fri Apr 22 23:26:47 2016 +0545

    Fixed ES_HOME typo

commit 79a2b0394297f8b02b6f71b71ba35ff79f1a684e
Author: Puru <tuladharpuru@gmail.com>
Date:   Sun Apr 10 11:00:24 2016 +0545

    Improve elasticsearch startup script test

    Added improvement as per conversation in https://github.com/elastic/elasticsearch/pull/17082#issuecomment-206459613

commit 7be38e1fefd4baa6ccdbdc14745c00f6dc052e0c
Author: Puru <tuladharpuru@gmail.com>
Date:   Wed Mar 23 13:23:52 2016 +0545

    Add elasticsearch startup script test

    The test ensures that elasticsearch startup script exists and is executable.

commit d10eed5c08260fa9c158a4487bbb3103a8d867ed
Author: Puru <tuladharpuru@gmail.com>
Date:   Wed Mar 23 12:30:25 2016 +0545

    Fixed IF syntax and failure message

commit 6dc66f616545572485b4d43bee05a4cbbf1bed72
Author: Puru <tuladharpuru@gmail.com>
Date:   Sat Mar 12 11:08:11 2016 +0545

    Fix exit code

    Exit with proper exit code (1) and an error message if elasticsearch executable binary does not exists or has insufficient permissions to execute.
2016-04-22 11:48:05 -06:00
Lee Hinman 4fca5f734a Explicitly set packaging permissions
This changes our packaging to be explicit about the permissions of files
and directories in the tar.gz, rpm, and deb packages. This is to protect
against a user having an incorrectly set umask when installing.

Additionally, plugins that are installed now have their permissions set
by the plugin installation so that plugins that may have been packaged
with incorrect permissions are secured.

Resolves #17634
2016-04-21 12:30:56 -06:00
Lee Hinman a1e8fb794c Allow JSON with unquoted field names by enabling system property
In Elasticsearch 5.0.0, by default unquoted field names in JSON will be
rejected. This can cause issues, however, for documents that were
already indexed with unquoted field names. To alleviate this, a system
property has been added that can be enabled so migration can occur.

This system property will be removed in Elasticsearch 6.0.0

Resolves #17674
2016-04-19 09:14:13 -06:00
Lee Hinman 66adcb2962 [TEST] Fix extra backslash causing sed to hang
This caused sed to hang and the output never to show for the smoke test
command
2016-04-13 10:24:39 -06:00
Jason Tedor a581d7cca4 Merge pull request #17675 from jasontedor/java-opts
Add JVM options configuration file
2016-04-12 23:07:40 -04:00
Jason Tedor 3879aa2a98 Add JVM options configuration file
This commit adds a new configuration file jvm.options to centralize and
simplify management of JVM options. This separates the configuration of
the JVM from the packaging scripts (bin/elasticsearch*, bin/service.bat,
and init.d/elasticsearch) simplifying end-user operational management of
custom JVM options.
2016-04-12 11:19:16 -04:00
Lee Hinman dd8afc9567 [TEST] Add extra logging for vagrant test output
The $user, $group, and $privileges are echoed when they are being
compared.
2016-04-11 09:36:50 -06:00
Ryan Ernst 19567fb794 Add stop task for vagrant which wraps all halt tasks, instead of using clean 2016-04-06 14:15:23 -07:00
Ryan Ernst bfc708ee58 Merge pull request #17573 from rjernst/vagrant_boxes_param
Tests: Add vagrant.boxes gradle property
2016-04-06 13:33:45 -07:00
Ryan Ernst dc376fb21b Tweak packagingTest description formatting 2016-04-06 13:08:38 -07:00
Ryan Ernst 9794d371ef Always add halt tasks for all available boxes 2016-04-06 13:07:11 -07:00
Ryan Ernst 9f24de7ca8 Tests: Add vagrant.boxes gradle property
This change makes specifying which boxes to run vagrant tests on a
little easier. Previously there were two tasks, checkPackages and
checkPackagesAllDistros. With this change, there is a single
packagingTest task. The boxes to run on are specified using the
gradle property vagrant.boxes, which can be easily specified on the
command line, or in a gradle properties file. There are also two
alias names, 'sample' for a yum and apt box, and 'all' for all boxes.
2016-04-06 12:36:35 -07:00
Jason Tedor eb7ecb7296 Add test of plugin script if JAVA_HOME has a space 2016-04-06 13:28:56 -04: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
Alexander Reelsen baec7bc23c Tests: Fix vagrant test on debian
Debian asks during installation, if the configuration file should be updated.
This is asked via a prompt and thus hangs.

This adds an option to always update to the newer config file, so automated
installation keeps working.
2016-03-24 14:21:33 +01:00
Simon Willnauer e4e08b28ff [TEST] Use to wait for the node to start - it will wait for state recovery and not return 503 2016-03-24 11:06:40 +01:00