@@ -137,7 +137,7 @@ class ClusterFormationTasks {
137
137
} else {
138
138
dependsOn = startTasks. empty ? startDependencies : startTasks. get(0 )
139
139
writeConfigSetup = { Map esConfig ->
140
- String unicastTransportUri = node. config. unicastTransportUri(nodes. get(0 ), node, project. ant )
140
+ String unicastTransportUri = node. config. unicastTransportUri(nodes. get(0 ), node, project. createAntBuilder() )
141
141
if (unicastTransportUri == null ) {
142
142
esConfig[' discovery.zen.ping.unicast.hosts' ] = []
143
143
} else {
@@ -705,7 +705,7 @@ class ClusterFormationTasks {
705
705
Collection<String > unicastHosts = new HashSet<> ()
706
706
nodes. forEach { node ->
707
707
unicastHosts. addAll(node. config. otherUnicastHostAddresses. call())
708
- String unicastHost = node. config. unicastTransportUri(node, null , project. ant )
708
+ String unicastHost = node. config. unicastTransportUri(node, null , project. createAntBuilder() )
709
709
if (unicastHost != null ) {
710
710
unicastHosts. addAll(Arrays . asList(unicastHost. split(" ," )))
711
711
}
@@ -901,9 +901,10 @@ class ClusterFormationTasks {
901
901
outputPrintStream : outputStream,
902
902
messageOutputLevel : org.apache.tools.ant.Project . MSG_INFO )
903
903
904
- project. ant. project. addBuildListener(listener)
905
- Object retVal = command(project. ant)
906
- project. ant. project. removeBuildListener(listener)
904
+ AntBuilder ant = project. createAntBuilder()
905
+ ant. project. addBuildListener(listener)
906
+ Object retVal = command(ant)
907
+ ant. project. removeBuildListener(listener)
907
908
return retVal
908
909
}
909
910
0 commit comments