Polish Elasticsearch health indicator

- Nest the configuration class in HealthIndicatorAutoConfiguration,
   bringing it into line with the other health indicator configuration
   classes
 - Include the statistics from the response in the health’s details
 - Map YELLOW to UP rather than UNKNOWN as it indicates that the cluster
   is running but that “the primary shard is allocated but replicas are
   not” [1]. The details can be used to determine the precise state of
   the cluster.
 - Add a property to configure the time that the health indicator will
   wait to receive a response from the cluster
 - Document the configuration properties
 - Update the tests to cover the updated functionality

See gh-2399

[1] http://www.elastic.co/guide/en/elasticsearch/reference/1.x/cluster-health.html
This commit is contained in:
Andy Wilkinson
2015-04-09 10:08:20 +01:00
parent 58c8c2ccdc
commit 03b109a2c8
12 changed files with 403 additions and 209 deletions

View File

@@ -63,6 +63,7 @@
<ehcache.version>2.9.1</ehcache.version>
<flyway.version>3.2</flyway.version>
<freemarker.version>2.3.22</freemarker.version>
<elasticsearch.version>1.4.4</elasticsearch.version>
<gemfire.version>7.0.2</gemfire.version>
<glassfish-el.version>3.0.0</glassfish-el.version>
<gradle.version>1.12</gradle.version>
@@ -1084,6 +1085,11 @@
<artifactId>websocket-server</artifactId>
<version>${jetty.version}</version>
</dependency>
<dependency>
<groupId>org.elasticsearch</groupId>
<artifactId>elasticsearch</artifactId>
<version>${elasticsearch.version}</version>
</dependency>
<dependency>
<groupId>org.flywaydb</groupId>
<artifactId>flyway-core</artifactId>