From dc51dd0056b06dfd7f07345e4d87abfe911c599c Mon Sep 17 00:00:00 2001 From: Daniel Mitterdorfer Date: Thu, 14 Jan 2016 09:48:27 +0100 Subject: [PATCH] Add more logging to wait condition for elasticsearch nodes in tests --- .../org/elasticsearch/gradle/test/ClusterConfiguration.groovy | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/buildSrc/src/main/groovy/org/elasticsearch/gradle/test/ClusterConfiguration.groovy b/buildSrc/src/main/groovy/org/elasticsearch/gradle/test/ClusterConfiguration.groovy index e308c1afda8..2741019b751 100644 --- a/buildSrc/src/main/groovy/org/elasticsearch/gradle/test/ClusterConfiguration.groovy +++ b/buildSrc/src/main/groovy/org/elasticsearch/gradle/test/ClusterConfiguration.groovy @@ -57,11 +57,12 @@ class ClusterConfiguration { @Input Closure waitCondition = { NodeInfo node, AntBuilder ant -> File tmpFile = new File(node.cwd, 'wait.success') - ant.echo(message: "[${LocalDateTime.now()}] Waiting for elasticsearch node", level: "info") + ant.echo(message: "[${LocalDateTime.now()}] Waiting for elasticsearch node ${node.httpUri()}", level: "info") ant.get(src: "http://${node.httpUri()}", dest: tmpFile.toString(), ignoreerrors: true, // do not fail on error, so logging buffers can be flushed by the wait task retries: 10) + ant.echo(message: "[${LocalDateTime.now()}] Finished waiting for elasticsearch node ${node.httpUri()}. Reachable? ${tmpFile.exists()}", level: "info") return tmpFile.exists() }