Fix bwc testcluster setup against elastic < 6.3
This commit is contained in:
parent
5c86b216e8
commit
0d488cfbb9
|
@ -453,7 +453,7 @@ public class ElasticsearchNode implements TestClusterConfiguration {
|
||||||
pluginsToInstall.addAll(plugins.stream().map(Provider::get).map(URI::toString).collect(Collectors.toList()));
|
pluginsToInstall.addAll(plugins.stream().map(Provider::get).map(URI::toString).collect(Collectors.toList()));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (getVersion().before("6.3.0") && testDistribution == TestDistribution.DEFAULT) {
|
if (requiresAddingXPack()) {
|
||||||
logToProcessStdout("emulating the " + testDistribution + " flavor for " + getVersion() + " by installing x-pack");
|
logToProcessStdout("emulating the " + testDistribution + " flavor for " + getVersion() + " by installing x-pack");
|
||||||
pluginsToInstall.add("x-pack");
|
pluginsToInstall.add("x-pack");
|
||||||
}
|
}
|
||||||
|
@ -524,8 +524,13 @@ public class ElasticsearchNode implements TestClusterConfiguration {
|
||||||
startElasticsearchProcess();
|
startElasticsearchProcess();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private boolean requiresAddingXPack() {
|
||||||
|
boolean b = getVersion().before("6.3.0") && testDistribution == TestDistribution.DEFAULT;
|
||||||
|
return getVersion().before("6.3.0") && testDistribution == TestDistribution.DEFAULT;
|
||||||
|
}
|
||||||
|
|
||||||
private boolean canUseSharedDistribution() {
|
private boolean canUseSharedDistribution() {
|
||||||
return extraJarFiles.size() == 0 && modules.size() == 0 && plugins.size() == 0;
|
return extraJarFiles.size() == 0 && modules.size() == 0 && plugins.size() == 0 && !requiresAddingXPack();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void logToProcessStdout(String message) {
|
private void logToProcessStdout(String message) {
|
||||||
|
|
Loading…
Reference in New Issue