From 4ded96ab68c888721ba5ca32a3d2428be443dab9 Mon Sep 17 00:00:00 2001 From: Ryan Ernst Date: Mon, 6 May 2019 12:32:31 -0700 Subject: [PATCH] Switch run task to use real distro (#41590) The run task is supposed to run elasticsearch with the given plugin or module. However, for modules, this is most realistic if using the full distribution. This commit changes the run setup to use the default or oss as appropriate. --- .../org/elasticsearch/gradle/plugin/PluginBuildPlugin.groovy | 3 +-- x-pack/plugin/ccr/build.gradle | 4 ---- x-pack/plugin/data-frame/build.gradle | 4 ---- x-pack/plugin/deprecation/build.gradle | 4 ---- x-pack/plugin/graph/build.gradle | 4 ---- x-pack/plugin/ilm/build.gradle | 3 --- x-pack/plugin/logstash/build.gradle | 4 ---- x-pack/plugin/ml/build.gradle | 4 ---- x-pack/plugin/monitoring/build.gradle | 4 ---- x-pack/plugin/rollup/build.gradle | 4 ---- x-pack/plugin/security/build.gradle | 4 ---- x-pack/plugin/watcher/build.gradle | 4 ---- 12 files changed, 1 insertion(+), 45 deletions(-) diff --git a/buildSrc/src/main/groovy/org/elasticsearch/gradle/plugin/PluginBuildPlugin.groovy b/buildSrc/src/main/groovy/org/elasticsearch/gradle/plugin/PluginBuildPlugin.groovy index 58ef5b6d323d4..d5bdd2117023c 100644 --- a/buildSrc/src/main/groovy/org/elasticsearch/gradle/plugin/PluginBuildPlugin.groovy +++ b/buildSrc/src/main/groovy/org/elasticsearch/gradle/plugin/PluginBuildPlugin.groovy @@ -99,9 +99,8 @@ class PluginBuildPlugin extends BuildPlugin { project.tasks.run.dependsOn(project.tasks.bundlePlugin) if (isModule) { - project.tasks.run.clusterConfig.module(project) project.tasks.run.clusterConfig.distribution = System.getProperty( - 'run.distribution', 'integ-test-zip' + 'run.distribution', isXPackModule ? 'default' : 'oss' ) } else { project.tasks.run.clusterConfig.plugin(project.path) diff --git a/x-pack/plugin/ccr/build.gradle b/x-pack/plugin/ccr/build.gradle index dbe1cdf51ef79..a808a7197cccb 100644 --- a/x-pack/plugin/ccr/build.gradle +++ b/x-pack/plugin/ccr/build.gradle @@ -59,10 +59,6 @@ dependencyLicenses { ignoreSha 'x-pack-core' } -run { - plugin xpackModule('core') -} - testingConventions.naming { IT { baseClass "org.elasticsearch.xpack.CcrIntegTestCase" diff --git a/x-pack/plugin/data-frame/build.gradle b/x-pack/plugin/data-frame/build.gradle index ad4d846fd160f..e065f72e99880 100644 --- a/x-pack/plugin/data-frame/build.gradle +++ b/x-pack/plugin/data-frame/build.gradle @@ -15,10 +15,6 @@ dependencies { testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') } -run { - plugin xpackModule('core') -} - // xpack modules are installed in real clusters as the meta plugin, so // installing them as individual plugins for integ tests doesn't make sense, // so we disable integ tests diff --git a/x-pack/plugin/deprecation/build.gradle b/x-pack/plugin/deprecation/build.gradle index d89eb62e88492..62d2a891929a4 100644 --- a/x-pack/plugin/deprecation/build.gradle +++ b/x-pack/plugin/deprecation/build.gradle @@ -13,8 +13,4 @@ dependencies { compileOnly "org.elasticsearch.plugin:x-pack-core:${version}" } -run { - plugin xpackModule('core') -} - integTest.enabled = false diff --git a/x-pack/plugin/graph/build.gradle b/x-pack/plugin/graph/build.gradle index f1bac2e54d455..e7b0b44fd659b 100644 --- a/x-pack/plugin/graph/build.gradle +++ b/x-pack/plugin/graph/build.gradle @@ -24,8 +24,4 @@ gradle.projectsEvaluated { .each { check.dependsOn it.check } } -run { - plugin xpackModule('core') -} - integTest.enabled = false diff --git a/x-pack/plugin/ilm/build.gradle b/x-pack/plugin/ilm/build.gradle index 71def8937817c..e6962e3c3bf72 100644 --- a/x-pack/plugin/ilm/build.gradle +++ b/x-pack/plugin/ilm/build.gradle @@ -29,6 +29,3 @@ gradle.projectsEvaluated { integTest.enabled = false -run { - plugin xpackModule('core') -} diff --git a/x-pack/plugin/logstash/build.gradle b/x-pack/plugin/logstash/build.gradle index 1057a1c8526fc..476d3f17cad41 100644 --- a/x-pack/plugin/logstash/build.gradle +++ b/x-pack/plugin/logstash/build.gradle @@ -15,8 +15,4 @@ dependencies { testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') } -run { - plugin xpackModule('core') -} - integTest.enabled = false diff --git a/x-pack/plugin/ml/build.gradle b/x-pack/plugin/ml/build.gradle index ef3b228a8bed7..8c17e4b1fc4c6 100644 --- a/x-pack/plugin/ml/build.gradle +++ b/x-pack/plugin/ml/build.gradle @@ -94,10 +94,6 @@ project.afterEvaluate { } } -run { - plugin xpackModule('core') -} - // xpack modules are installed in real clusters as the meta plugin, so // installing them as individual plugins for integ tests doesn't make sense, // so we disable integ tests diff --git a/x-pack/plugin/monitoring/build.gradle b/x-pack/plugin/monitoring/build.gradle index 5d17b81e2fa3c..b2e0c930e0d61 100644 --- a/x-pack/plugin/monitoring/build.gradle +++ b/x-pack/plugin/monitoring/build.gradle @@ -45,10 +45,6 @@ dependencyLicenses { mapping from: /commons-.*/, to: 'commons' // pulled in by rest client } -run { - plugin xpackModule('core') -} - // xpack modules are installed in real clusters as the meta plugin, so // installing them as individual plugins for integ tests doesn't make sense, // so we disable integ tests diff --git a/x-pack/plugin/rollup/build.gradle b/x-pack/plugin/rollup/build.gradle index 75fd22abacc58..d159f3334b998 100644 --- a/x-pack/plugin/rollup/build.gradle +++ b/x-pack/plugin/rollup/build.gradle @@ -21,8 +21,4 @@ dependencies { testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') } -run { - plugin xpackModule('core') -} - integTest.enabled = false diff --git a/x-pack/plugin/security/build.gradle b/x-pack/plugin/security/build.gradle index cab1a7f8d6e3b..27d0db1a48a86 100644 --- a/x-pack/plugin/security/build.gradle +++ b/x-pack/plugin/security/build.gradle @@ -301,10 +301,6 @@ thirdPartyAudit.ignoreMissingClasses( ) -run { - plugin xpackModule('core') -} - test { /* * We have to disable setting the number of available processors as tests in the same JVM randomize processors and will step on each diff --git a/x-pack/plugin/watcher/build.gradle b/x-pack/plugin/watcher/build.gradle index 0b5faddaab42d..a44665ca25c0f 100644 --- a/x-pack/plugin/watcher/build.gradle +++ b/x-pack/plugin/watcher/build.gradle @@ -69,10 +69,6 @@ thirdPartyAudit { ) } -run { - plugin xpackModule('core') -} - test { /* * We have to disable setting the number of available processors as tests in the same JVM randomize processors and will step on each