Commit Graph

282 Commits

Author SHA1 Message Date
Ryan Ernst 6a99796b02 Build: Move test framework under a "test" top level dir
This allows adding more test projects, eg integ test fixtures that will
be coming soon.
2015-12-17 21:25:06 -08:00
Robert Muir ee79d46583 Add gradle thirdPartyAudit to precommit tasks 2015-12-16 16:38:16 -05:00
Costin Leau 7bca97bba6 HDFS Snapshot/Restore plugin
Migrated from ES-Hadoop. Contains several improvements regarding:

* Security
Takes advantage of the pluggable security in ES 2.2 and uses that in order
to grant the necessary permissions to the Hadoop libs. It relies on a
dedicated DomainCombiner to grant permissions only when needed only to the
libraries installed in the plugin folder
Add security checks for SpecialPermission/scripting and provides out of
the box permissions for the latest Hadoop 1.x (1.2.1) and 2.x (2.7.1)

* Testing
Uses a customized Local FS to perform actual integration testing of the
Hadoop stack (and thus to make sure the proper permissions and ACC blocks
are in place) however without requiring extra permissions for testing.
If needed, a MiniDFS cluster is provided (though it requires extra
permissions to bind ports)
Provides a RestIT test

* Build system
Picks the build system used in ES (still Gradle)
2015-12-14 21:50:09 +02:00
Ryan Ernst fa1c708ccd Merge branch 'master' into standalone_tests_intellij 2015-12-07 16:01:32 -08:00
Ryan Ernst caf77f7eea Add integ-test-zip distribution 2015-12-03 14:52:51 -08:00
Ryan Ernst 30fe74b5df Build: Setup standalone tests to compile in intellij
This adds the standalone tests so they will compile (and thus can be
modified with import completion) within IntelliJ. It also explicitly
sets up buildSrc as a module.

Note that this does *not* mean eg evil-tests can be run from intellij.
These are special tests that require special settings (eg disabling
security manager). They need to be run from the command line.

closes #15075
2015-11-28 16:57:09 -08:00
Nik Everett 45e71329ee [build] Fix deb and rpm tests
Gradle is causing so much trouble here! Its too cute for its own good.
2015-11-28 19:07:06 -05:00
Ryan Ernst 3071de2d33 Build: Enforce that gradle idea was run before importing in intellij
Due to how intellij imports gradle projects, the tasks which setup
resources are not run. This means we must be sure to run gradle idea
from the command line before importing into elasticsearch. This change
adds a simple marker file to indicate we have run from the command line
before importing. It won't help for new projects that add plugin
metadata, but it will at least make sure the initial project is set up
correctly.
2015-11-22 16:07:39 -08:00
Ryan Ernst 6b2f3a9ad2 Fix bad merge 2015-11-22 08:51:34 -08:00
Ryan Ernst b8e462b934 Build: Change project attachment into special extra-plugins dir
Currently we use the "gradle project attachment plugin" to support
building elasticsearch as part of another project. However, this plugin
has a number of issues, a large part of which is requiring consistent
use of the projectsPrefix.

This change removes projectsPrefix, and adds support for a special
extra-plugins directory in the root of elasticsearch. Any projects
checked out within this directory will be automatically added to
elasticsearch.
2015-11-22 08:44:33 -08:00
Ryan Ernst f9351b3e0e Build: Enforce similar tasks run for dependencies first
Gradle ensures task dependencies are executed in the correct order.
However, project dependencies only build what is needed for the
dependency. This means the order of higher level tasks are not
guaranteed. This change adds task ordering between test and integTest
for a project and its dependencies.
2015-11-22 01:17:49 -08:00
Ryan Ernst 88ee2e23a6 Merge branch 'master' into javadocs 2015-11-20 12:20:59 -08:00
Ryan Ernst 167ccefba6 Add reference to gradle discussion on javadoc options 2015-11-20 12:18:30 -08:00
Ryan Ernst 28cba31447 Build: Remove cleaning of buildSrc on clean of ES, it doens't work as intended 2015-11-20 09:47:48 -08:00
Ryan Ernst 1952b06cfe Merge pull request #14854 from rjernst/trick_ant
Fix integTest output if the elasticsearch script fails
2015-11-19 12:03:03 -08:00
Ryan Ernst eb09d0b680 Add a comment explaining the -quiet parameter for adding javadoc options 2015-11-19 11:15:00 -08:00
Ryan Ernst c3cb1fd08c Merge branch 'master' into javadocs 2015-11-19 10:43:43 -08:00
Jason Tedor cac281424c Stop Gradle from destroying IntelliJ project settings
This commit stops Gradle from destroying the IntelliJ project settings
when a Gradle refresh is executed in IntelliJ.

Closes #14809
2015-11-19 07:42:19 -05:00
Ryan Ernst d44dbd4757 Build: Fix integTest output if the elasticsearch script fails
If there is a failure in the elasticsearch start script, we currently
completely lose the failure. This is due to how spawning works with ant.
This change avoids the issue by introducing an intermediate script,
built dynamically before running ant exec, which runs elasticsearch and
redirects the output to a log file. This essentially causes us to run
elasticsearch in the foreground and capture the output, but at the same
time keep a running script which ant can pump streams from (which will
always be empty).
2015-11-18 23:30:33 -08:00
Ryan Ernst 0e8d605e2d Build: Add --debug-jvm option to run and integTest tasks
Sometimes when running elasticsearch, it is useful to attach a remote
debugger. This change adds a --debug-jvm option (the same name gradle
uses for its tests debug option), which adds java agent config for a
remote debugger. The configuration is set to hava java suspend until the
remove debugger is attached.

closes #14772
2015-11-17 16:29:01 -08:00
Ryan Ernst 50b48e7d8c Build: Make run command work within plugins
We recently got a run command with gradle, but it is sometimes useful to
run ES with a specific plugin. This is a start, by making each esplugin
have a run command which installs the plugin and runs elasticsearch in
the foreground.
2015-11-16 17:29:01 -08:00
Ryan Ernst ee16614911 Build: Also clean buildSrc when cleaning
This forces buildSrc to be cleaned when running gradle clean. It's what
someone would expect, even though buildSrc is a pseudo-independent
project.
2015-11-16 12:41:21 -08:00
Ryan Ernst 4b17492456 Build: Add javadocs jars
This change adds javadoc jars to core, test-framework and plugins. There
were a couple issues which javadoc found, but doclint did not already
find.
2015-11-15 01:44:42 -08:00
Ryan Ernst 837c593ec2 Build: Effectively remove transitive deps from generated maven poms
With gradle, deploying to maven means first generating poms. These are
filled in based on dependencies of the project. Recently, we started
disallowing transitive dependencies. However, this configuration does
not translate to maven poms because maven has no concept of excluding
all transitive dependencies.

This change adds exclusions for each of the transitive deps of each
dependency being added to the maven pom. It does so by creating dummy
configurations for each direct dependency (which does not have
transitive deps excluded), so that we can iterate the transitive deps
when building the pom.

Note, this should be simpler (just modifying maven's pom model), but
gradle tries to hide that from their api, causing us to need to
manipulate the xml directly.
https://discuss.gradle.org/t/modifying-maven-pom-generation-to-add-excludes/12744
2015-11-13 14:10:17 -08:00
Ryan Ernst f327beac49 Build: Enforce JAVA_HOME is set
If we use JAVA_HOME consistently for tests, we can run tests with a
different version of java than gradle runs with. For example, this
enables running tests with jigsaw, but building with java 8. The only
caveat is intellij does not set JAVA_HOME. This change enforces
JAVA_HOME is set, but ignores for intellij.
2015-11-12 10:22:56 -08:00
Ryan Ernst 505a4d9e09 Build: Simplify where min java version is specified
This moves the min java version used by elasticsearch to one place, a
constant in BuildPlugin. For me on java 9, this fixed my jar to have the
correct target/source versions.

closes #14702
2015-11-11 23:09:57 -08:00
Ryan Ernst 4b5f87cb7d Build: Remove transitive dependencies
Transitive dependencies can be confusing and hard to deal with when
conflicts arise between them. This change removes transitive
dependencies from elasticsearch, and forces any dependency conflicts to
be resolved manually, instead of automatically by gradle.

closes #14627
2015-11-10 15:01:41 -08:00
Ryan Ernst 7a6155e12f Build: Consolidate dependencies specified in multiple places
Some dependencies must be specified in a couple places in the build.
e.g. randomized runner is specified both in buildSrc (for the gradle
wrapper plugin), as well as in the test-framework.

This change creates buildSrc/versions.properties which acts similar to
the set of shared version properties we used to have in the maven parent
pom.
2015-11-09 23:59:56 -08:00
andrejserafim 2bd353d72d replacing run.bat and run.sh with gradle run
run.sh and run.bat were calling out to the old maven build system.
This is no longer in place, so we've created new gradle tasks to
start an elasticsearch node from the current codebase.

fixed #14423
2015-11-08 17:07:19 +00:00
Robert Muir 866a514785 add groovy build code (buildSrc/) in 'gradle eclipse'
This makes it a groovy project that works in eclipse.
You will have to install a plugin for groovy language support
(I used a snapshot build from https://github.com/groovy/groovy-eclipse/wiki)
2015-11-07 15:14:00 -05:00
Ryan Ernst 548430072f Build: Fix eclipse generation to add a core-tests projects
Eclipse does not have the ability to differentiate test dependencies
from main dependencies. This causes what looks like a circular
dependency through test-framework. This change sets up an additional
core-tests project for eclipse only, which removes this problem.
2015-11-06 11:41:18 -08:00
Robert Muir 1a0a910d1e Merge pull request #14526 from rjernst/standalone_test
Add qa/evil-tests
2015-11-04 13:49:55 -05:00
Ryan Ernst a534ace896 Fix standalone test to work with check, and comment out mavenLocal 2015-11-04 10:28:31 -08:00
Robert Muir 3d8b4dae33 remove the ability for code to change file permissions, this was
only needed for pluginmanager's test, and pluginmanager doesn't
even run with securitymanager yet.
2015-11-04 00:31:15 -05:00
Ryan Ernst 3e4f87d4d6 Fix tar issues and build distro dependency for integ tests 2015-11-02 22:19:29 -08:00
Ryan Ernst b7f8e5c1df Build: Make idea/eclipse project generation build generated resources for plugins
This adds a generated-resources dir that the plugin properties are
generated into. This must be outside of the build dir, since intellij
has build as "excluded".

closes #14392
2015-11-02 11:35:02 -08:00
Robert Muir 4587a94fcf generate complete eclipse configuration from 'gradle eclipse' 2015-11-02 10:44:51 -05:00
Robert Muir 9056ebb20d gradle cleanEclipse should completely nuke .settings.
Today this will only remove `.settings/org.eclipse.jdt.core.prefs`,
leaving a bunch of stale eclipse configuration everywhere.
2015-11-02 09:39:14 -05:00
Robert Muir 3961c9b58b fix eclipse (again) 2015-10-31 02:39:35 -04:00
Ryan Ernst 0dca49fae4 fix eclipse config for qa projects 2015-10-30 21:32:16 -07:00
Robert Muir 373dee4b5e make gradle eclipse always run cleanEclipse
Otherwise the 'merging' gets really trappy. it basically never works without a clean.

See 38.4.1.1. Disabling merging with a complete rewrite:
https://docs.gradle.org/current/userguide/eclipse_plugin.html
2015-10-30 23:00:05 -04:00
Robert Muir 10d4f17aa8 make eclipse work without specifying a sysprop 2015-10-30 14:21:06 -04:00
Robert Muir 9bdc10802e Get eclipse working with gradle 2015-10-30 11:39:31 -04:00
Ryan Ernst 561436eba3 Build: Add back manifest info to jars
closes #14365
2015-10-29 13:59:52 -07:00
Ryan Ernst c86100f636 Switch build system to Gradle
See #13930
2015-10-29 11:40:19 -07:00
Shay Banon bf0caafa04 remove old modules and gradle 2011-12-06 01:01:04 +02:00
Shay Banon 49a97f6fcf move to 0.19.0 snap 2011-10-26 21:04:10 +02:00
Shay Banon 3544b07330 release 0.18.0 2011-10-26 20:58:24 +02:00
Nicolas Huray d7f7f77d81 Build ElasticSearch as Debian package 2011-09-28 01:08:35 +03:00
kimchy d4e18f5f45 move to 0.18 release 2011-07-19 01:34:55 +03:00
kimchy eacdacb410 0.17 release 2011-07-19 01:32:43 +03:00
kimchy 2dd6075171 maybe we will do this later... 2011-07-15 10:19:36 +03:00
kimchy 1f70be7de2 fix testng deps 2011-07-08 00:56:52 +03:00
Igor Motov e5f2dfbf0e Add missing testng dependencies 2011-07-08 00:50:22 +03:00
kimchy 420ed9daa6 upgrade to testng 6.1.1 2011-07-06 23:15:03 +03:00
kimchy 67dc32100d upgrade gradle to 1.0 m3 2011-06-13 14:38:00 +03:00
kimchy 84c5d07726 move to 0.17.0-SNAPSHOT 2011-04-23 23:56:12 +03:00
kimchy 0ebd6db7b9 release 0.16.0 2011-04-23 23:48:15 +03:00
kimchy bcf8bc5993 update to next 0.16.0 version 2011-02-18 19:52:17 +02:00
kimchy dac2a888fb update to version 0.15 2011-02-18 19:49:30 +02:00
kimchy 0e595532f7 add maxMem to the heapsize when executing tests 2011-02-09 20:45:21 +02:00
kimchy 00cba66eb8 move to use mvel 2.1.RC1 2011-02-03 11:29:24 +02:00
kimchy c7add5f377 upgrade to mvel 2.1 snapshot to gain performance improvements 2011-01-31 21:41:23 +02:00
kimchy 2820988171 upgrade to gradle 0.9.2 2011-01-30 16:05:05 +02:00
kimchy 9ff8006d37 have compilation and javadoc use UTF8 encoding 2011-01-20 14:24:12 +02:00
kimchy 84fa13a5e0 upgrade to gradle 0.9.1 2011-01-03 11:45:59 +02:00
kimchy 8e8a3a894f upgrade testing framework jars, improve build scripts to share the testing jars 2010-12-30 16:08:38 +02:00
kimchy bb4017769e update to 0.15.0 SNAPSHOT 2010-12-27 22:25:34 +02:00
kimchy 956e775a4e release 0.14 2010-12-27 22:23:18 +02:00
kimchy ec943b5160 fix urlRoot for gradle to point to the 0.9 dist 2010-12-20 17:58:16 +02:00
kimchy 09bc3b90e7 upgrade to gradle 0.9 2010-12-19 19:53:50 +02:00
kimchy 29c7fc39ba upgrade to gradle 0.9 rc3 2010-12-19 05:51:15 +02:00
kimchy 5d43e6ff30 update to 0.14.0 SNAPSHOT 2010-11-18 17:00:18 +02:00
kimchy 7ec6e00b6f release 0.13 2010-11-18 16:40:21 +02:00
kimchy 9bddd6770c Add a tar.gz distribution file as well as the zip one 2010-11-06 01:28:10 +02:00
kimchy be96e9495a upgrade to gradle 0.9 rc2 2010-10-30 19:57:50 +02:00
kimchy 96a1ad6335 When on linux, force it not to swap elasticsearch process (jvm), closes #464. 2010-10-30 19:40:24 +02:00
kimchy c38f07a713 update to 0.13.0 SNAPSHOT 2010-10-18 23:21:29 +02:00
kimchy 27ee635933 update to release 0.12 2010-10-18 23:17:34 +02:00
kimchy 64662d8449 update to 0.12.0 SNAPSHOT version 2010-09-28 22:20:22 +02:00
kimchy 67c205722d release 0.11 2010-09-28 22:14:34 +02:00
kimchy 6a79a16e5b move to 0.11 snapshot 2010-08-27 17:48:51 +03:00
kimchy 153523cf7d update to version 0.10.0 2010-08-27 17:28:27 +03:00
kimchy 80c71350cd change from 0.9.1 to version 0.10.0 2010-08-24 01:29:17 +03:00
kimchy b78597934f expose the maven params in the build files as sys envs 2010-08-20 17:50:04 +03:00
kimchy c7f765d025 add (commented) playing with trying to execute from gradle 2010-08-16 12:56:45 +03:00
kimchy 12bacbbc38 upgrade to gradle 0.9-rc-1 2010-08-16 12:43:14 +03:00
kimchy cb92d22e84 move to 0.9.1 snapshot release 2010-07-26 23:05:02 +03:00
kimchy 2cded30f4c release 0.9.0 2010-07-26 23:02:25 +03:00
kimchy b1c0a78c8e add snapshot repo 2010-07-22 23:33:38 +03:00
kimchy 97b5b41522 enable eager cache eviction based on readers, requires a nasty hack to Lucene, basically overriding two classes to hook into when a reader actually gets closed (and only enabled when elasticsearch is before lucene in the classpath, which we take for in the startup scripts) 2010-07-07 17:15:26 +03:00
kimchy 0d7cebbaf0 upgrade to async http client 1.0.0 2010-06-23 21:51:29 +03:00
kimchy 636bfe8466 big refactoring thanks to proper jarjar built from source with asm 3.3 allowing to jarjar guice and others, includes package relocations 2010-06-15 16:51:38 +03:00
kimchy 751c56f31e Query DSL: custom score (scripted) query, closes #220. 2010-06-14 03:15:23 +03:00
kimchy 288aa36a39 upgrade to gradle 0.9 preview3 2010-06-11 01:02:27 +03:00
kimchy 8cc2638be8 update to 0.9.0 SNAPSHOT 2010-05-27 19:30:48 +03:00
kimchy 5be8ef9fd2 release 0.8.0 2010-05-27 18:59:51 +03:00
kimchy b7d11f1303 Gateway Storage: Improve it to support non breaking changes in the future, closes #191. 2010-05-24 18:27:48 +03:00
kimchy 6185e439c7 next version will be 0.7.2 2010-05-18 23:37:46 +03:00
kimchy d3881947ce change to 0.8.0-SNAPSHOT 2010-05-17 01:55:14 +03:00
kimchy bb3a3785f3 releasing version 0.7.1 2010-05-17 01:38:50 +03:00
kimchy be3c4b0196 version 0.7.1 will be released soon, not 0.8.0 2010-05-16 17:56:24 +03:00
kimchy d22ffa8c21 move to 0.8.0 SNAPSHOT 2010-05-14 23:29:04 +03:00
kimchy 797cb66dbe release 0.7.0 2010-05-14 23:15:53 +03:00
kimchy 2642eca9af fix the jboss repo 2010-05-14 18:23:10 +03:00
kimchy f6a1a2fefb add back old jboss repo for jarjar 2010-05-13 21:26:42 +03:00
kimchy f6777f1e03 jarjar netty as well, so it won't be exposed to users using elasticsearch embedded 2010-05-13 14:41:50 +03:00
kimchy ece1395b57 update repository 2010-05-12 17:43:34 +03:00
kimchy f6509930c7 upgrade to netty 3.2.0 CR1 2010-05-12 04:03:20 +03:00
kimchy 371bfebd16 initial support for process monitoring using sigar 2010-05-06 21:07:24 +03:00
kimchy b0e1c58474 Add online plugin repository and a 'plugin' command to download them, closes #157 2010-05-03 10:49:50 +03:00
kimchy 9651789870 jarjar snakeyaml and remove it from our sources now that it is in maven repo 2010-05-02 18:01:58 +03:00
kimchy 97958c3a66 Service Wrapper: A Java Service Wrapper integration, closes #154. 2010-05-01 01:42:30 +03:00
kimchy 70a2a3ef52 jarjar jackson and joda 2010-04-30 19:00:17 +03:00
kimchy dfd002bf98 add custom elasticsearch repo on google code 2010-04-27 14:47:32 +03:00
kimchy 10f0eaad68 refactor plugins into sub groups 2010-04-25 23:01:00 +03:00
kimchy bda476eee8 Remove dependency on slf4j for logging, create own internal abstraction, closes #146. 2010-04-21 00:29:42 +03:00
kimchy cb7e92b0f8 start work on the groovy plugin 2010-04-14 08:34:47 +03:00
kimchy f10a2d428d move to 0.7.0 2010-04-09 18:19:37 +03:00
kimchy 9549b9c2d3 fix wrong handling of doc ids to load when request is not serialized 2010-04-09 17:06:09 +03:00
kimchy dad0686fa9 fix chmod of elasticsearch in dist zip 2010-04-02 20:39:27 +03:00
kimchy 6ed23744fc upgrade to gradle 0.9 preview 1 2010-04-02 15:47:27 +03:00
kimchy 691a336b9a bring out exploded 2010-03-29 13:53:09 +03:00
kimchy 7c402507fe bring back the exploded plugin 2010-03-29 13:52:36 +03:00
kimchy b799b7a9d7 plugins support + start work on attachments plugin 2010-03-27 23:43:59 +03:00
kimchy 58319b1113 back to 0.6.0 2010-03-09 13:33:21 +02:00
kimchy 79e1df14e0 prepare for 0.5.1 2010-03-09 13:30:49 +02:00
kimchy 729baa6859 move to 0.6.0 2010-03-05 16:21:19 +02:00
kimchy bd8d52f3f8 move to SNAPSHOT suffix for dev builds, when an actual release will take place, then change the version 2010-03-01 16:30:07 +02:00
kimchy 18a1a5f940 merge snakeyaml into source 2010-03-01 15:50:02 +02:00
kimchy 7004a9e5ba bump to version 0.4.0 2010-02-08 15:36:23 +02:00
kimchy b3337c3127 initial commit 2010-02-08 15:30:06 +02:00