Set feature flags for IndexTemplatesV2 in top-level gradle file (#53898)
Resolves #53892
This commit is contained in:
parent
f0674af132
commit
1f3de2fa7e
11
build.gradle
11
build.gradle
|
@ -547,3 +547,14 @@ allprojects {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
// TODO: remove this once 7.7 is released and the 7.x branch is 7.8
|
||||
subprojects {
|
||||
pluginManager.withPlugin('elasticsearch.testclusters') {
|
||||
testClusters.all {
|
||||
if (org.elasticsearch.gradle.info.BuildParams.isSnapshotBuild() == false) {
|
||||
systemProperty 'es.itv2_feature_flag_registered', 'true'
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
import org.elasticsearch.gradle.info.BuildParams
|
||||
/*
|
||||
* Licensed to Elasticsearch under one or more contributor
|
||||
* license agreements. See the NOTICE file distributed with
|
||||
|
@ -33,9 +32,3 @@ integTest.runner {
|
|||
systemProperty 'tests.logfile', '--external--'
|
||||
}
|
||||
}
|
||||
|
||||
testClusters.integTest {
|
||||
if (BuildParams.isSnapshotBuild() == false) {
|
||||
systemProperty 'es.itv2_feature_flag_registered', 'true'
|
||||
}
|
||||
}
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
* under the License.
|
||||
*/
|
||||
|
||||
import org.elasticsearch.gradle.info.BuildParams
|
||||
|
||||
apply plugin: 'elasticsearch.testclusters'
|
||||
apply plugin: 'elasticsearch.standalone-rest-test'
|
||||
apply plugin: 'elasticsearch.rest-test'
|
||||
|
@ -48,9 +46,3 @@ integTest.runner {
|
|||
].join(',')
|
||||
}
|
||||
}
|
||||
|
||||
testClusters.integTest {
|
||||
if (BuildParams.isSnapshotBuild() == false) {
|
||||
systemProperty 'es.itv2_feature_flag_registered', 'true'
|
||||
}
|
||||
}
|
||||
|
|
|
@ -378,9 +378,6 @@ public class ActionModule extends AbstractModule {
|
|||
|
||||
static {
|
||||
final String property = System.getProperty("es.itv2_feature_flag_registered");
|
||||
if (Build.CURRENT.isSnapshot() && property != null) {
|
||||
throw new IllegalArgumentException("es.itv2_feature_flag_registered is only supported in non-snapshot builds");
|
||||
}
|
||||
if (Build.CURRENT.isSnapshot() || "true".equals(property)) {
|
||||
ITV2_FEATURE_FLAG_REGISTERED = true;
|
||||
} else if ("false".equals(property) || property == null) {
|
||||
|
|
|
@ -1,5 +1,3 @@
|
|||
import org.elasticsearch.gradle.info.BuildParams
|
||||
|
||||
apply plugin: 'elasticsearch.testclusters'
|
||||
apply plugin: 'elasticsearch.standalone-rest-test'
|
||||
apply plugin: 'elasticsearch.rest-test'
|
||||
|
@ -39,9 +37,3 @@ testClusters.integTest {
|
|||
user username: System.getProperty('tests.rest.cluster.username', 'test_user'),
|
||||
password: System.getProperty('tests.rest.cluster.password', 'x-pack-test-password')
|
||||
}
|
||||
|
||||
testClusters.integTest {
|
||||
if (BuildParams.isSnapshotBuild() == false) {
|
||||
systemProperty 'es.itv2_feature_flag_registered', 'true'
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue