Browse Source

Merge pull request #5328 from anandshah123/feature/gh-5326

* pr/5328:
  Polish contribution
  Rename HealthIndicatorAutoConfigurationProperties
pull/5337/head
Stephane Nicoll 10 years ago
parent
commit
a603201f05
  1. 8
      spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/HealthIndicatorAutoConfiguration.java
  2. 4
      spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/HealthIndicatorProperties.java

8
spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/HealthIndicatorAutoConfiguration.java

@ -100,18 +100,18 @@ import org.springframework.mail.javamail.JavaMailSenderImpl; @@ -100,18 +100,18 @@ import org.springframework.mail.javamail.JavaMailSenderImpl;
RabbitAutoConfiguration.class, SolrAutoConfiguration.class,
MailSenderAutoConfiguration.class, JmsAutoConfiguration.class,
ElasticsearchAutoConfiguration.class })
@EnableConfigurationProperties({ HealthIndicatorAutoConfigurationProperties.class })
@EnableConfigurationProperties({ HealthIndicatorProperties.class })
public class HealthIndicatorAutoConfiguration {
@Autowired
private HealthIndicatorAutoConfigurationProperties configurationProperties = new HealthIndicatorAutoConfigurationProperties();
private HealthIndicatorProperties properties = new HealthIndicatorProperties();
@Bean
@ConditionalOnMissingBean(HealthAggregator.class)
public OrderedHealthAggregator healthAggregator() {
OrderedHealthAggregator healthAggregator = new OrderedHealthAggregator();
if (this.configurationProperties.getOrder() != null) {
healthAggregator.setStatusOrder(this.configurationProperties.getOrder());
if (this.properties.getOrder() != null) {
healthAggregator.setStatusOrder(this.properties.getOrder());
}
return healthAggregator;
}

4
spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/HealthIndicatorAutoConfigurationProperties.java → spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/HealthIndicatorProperties.java

@ -1,5 +1,5 @@ @@ -1,5 +1,5 @@
/*
* Copyright 2012-2014 the original author or authors.
* Copyright 2012-2016 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@ -27,7 +27,7 @@ import org.springframework.boot.context.properties.ConfigurationProperties; @@ -27,7 +27,7 @@ import org.springframework.boot.context.properties.ConfigurationProperties;
* @since 1.2.0
*/
@ConfigurationProperties("management.health.status")
public class HealthIndicatorAutoConfigurationProperties {
public class HealthIndicatorProperties {
/**
* Comma-separated list of health statuses in order of severity.
Loading…
Cancel
Save