From 7f4b54842b99099838f618ecb1df3c06d9f6d8de Mon Sep 17 00:00:00 2001 From: Joe Fleming Date: Fri, 26 Feb 2016 16:58:09 -0700 Subject: [PATCH] use requestTimeout setting for health check Fixes #6377 --- src/plugins/elasticsearch/lib/health_check.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/plugins/elasticsearch/lib/health_check.js b/src/plugins/elasticsearch/lib/health_check.js index 15fc7b686a656..050bb85849671 100644 --- a/src/plugins/elasticsearch/lib/health_check.js +++ b/src/plugins/elasticsearch/lib/health_check.js @@ -22,7 +22,7 @@ module.exports = function (plugin, server) { plugin.status.yellow('Waiting for Elasticsearch'); function waitForPong() { - return client.ping({ requestTimeout: 1500 }).catch(function (err) { + return client.ping({ requestTimeout: config.get('elasticsearch.requestTimeout') }).catch(function (err) { if (!(err instanceof NoConnections)) throw err; plugin.status.red(format('Unable to connect to Elasticsearch at %s.', config.get('elasticsearch.url')));