mirror of
https://github.com/honeymoose/OpenSearch.git
synced 2025-02-08 22:14:59 +00:00
Merge pull request #20134 from rjernst/plugin_run_config
Build: Allow plugin to set run configuration distro to zip
This commit is contained in:
commit
acbece5b55
@ -72,10 +72,9 @@ class ClusterFormationTasks {
|
|||||||
throw new GradleException("bwcVersion must not be null if numBwcNodes is > 0")
|
throw new GradleException("bwcVersion must not be null if numBwcNodes is > 0")
|
||||||
}
|
}
|
||||||
// this is our current version distribution configuration we use for all kinds of REST tests etc.
|
// this is our current version distribution configuration we use for all kinds of REST tests etc.
|
||||||
project.configurations {
|
String distroConfigName = "${task.name}_elasticsearchDistro"
|
||||||
elasticsearchDistro
|
Configuration distro = project.configurations.create(distroConfigName)
|
||||||
}
|
configureDistributionDependency(project, config.distribution, distro, VersionProperties.elasticsearch)
|
||||||
configureDistributionDependency(project, config.distribution, project.configurations.elasticsearchDistro, VersionProperties.elasticsearch)
|
|
||||||
if (config.bwcVersion != null && config.numBwcNodes > 0) {
|
if (config.bwcVersion != null && config.numBwcNodes > 0) {
|
||||||
// if we have a cluster that has a BWC cluster we also need to configure a dependency on the BWC version
|
// if we have a cluster that has a BWC cluster we also need to configure a dependency on the BWC version
|
||||||
// this version uses the same distribution etc. and only differs in the version we depend on.
|
// this version uses the same distribution etc. and only differs in the version we depend on.
|
||||||
@ -91,10 +90,9 @@ class ClusterFormationTasks {
|
|||||||
// we start N nodes and out of these N nodes there might be M bwc nodes.
|
// we start N nodes and out of these N nodes there might be M bwc nodes.
|
||||||
// for each of those nodes we might have a different configuratioon
|
// for each of those nodes we might have a different configuratioon
|
||||||
String elasticsearchVersion = VersionProperties.elasticsearch
|
String elasticsearchVersion = VersionProperties.elasticsearch
|
||||||
Configuration configuration = project.configurations.elasticsearchDistro
|
|
||||||
if (i < config.numBwcNodes) {
|
if (i < config.numBwcNodes) {
|
||||||
elasticsearchVersion = config.bwcVersion
|
elasticsearchVersion = config.bwcVersion
|
||||||
configuration = project.configurations.elasticsearchBwcDistro
|
distro = project.configurations.elasticsearchBwcDistro
|
||||||
}
|
}
|
||||||
NodeInfo node = new NodeInfo(config, i, project, task, elasticsearchVersion, sharedDir)
|
NodeInfo node = new NodeInfo(config, i, project, task, elasticsearchVersion, sharedDir)
|
||||||
if (i == 0) {
|
if (i == 0) {
|
||||||
@ -105,7 +103,7 @@ class ClusterFormationTasks {
|
|||||||
config.seedNodePortsFile = node.transportPortsFile;
|
config.seedNodePortsFile = node.transportPortsFile;
|
||||||
}
|
}
|
||||||
nodes.add(node)
|
nodes.add(node)
|
||||||
startTasks.add(configureNode(project, task, cleanup, node, configuration))
|
startTasks.add(configureNode(project, task, cleanup, node, distro))
|
||||||
}
|
}
|
||||||
|
|
||||||
Task wait = configureWaitTask("${task.name}#wait", project, nodes, startTasks)
|
Task wait = configureWaitTask("${task.name}#wait", project, nodes, startTasks)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user