@Configuration(proxyBeanMethods=false)
@ConditionalOnClass(value={org.springframework.jdbc.core.JdbcTemplate.class,org.springframework.jdbc.datasource.lookup.AbstractRoutingDataSource.class})
@ConditionalOnBean(value=javax.sql.DataSource.class)
@ConditionalOnEnabledHealthIndicator(value="db")
@AutoConfigureAfter(value=org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration.class)
@EnableConfigurationProperties(value=DataSourceHealthIndicatorProperties.class)
public class DataSourceHealthContributorAutoConfiguration
extends java.lang.Object
implements org.springframework.beans.factory.InitializingBean
Auto-configuration for
DataSourceHealthIndicator.| Constructor and Description |
|---|
DataSourceHealthContributorAutoConfiguration(org.springframework.beans.factory.ObjectProvider<org.springframework.boot.jdbc.metadata.DataSourcePoolMetadataProvider> metadataProviders) |
| Modifier and Type | Method and Description |
|---|---|
void |
afterPropertiesSet() |
org.springframework.boot.actuate.health.HealthContributor |
dbHealthContributor(java.util.Map<java.lang.String,javax.sql.DataSource> dataSources,
DataSourceHealthIndicatorProperties dataSourceHealthIndicatorProperties) |
public DataSourceHealthContributorAutoConfiguration(org.springframework.beans.factory.ObjectProvider<org.springframework.boot.jdbc.metadata.DataSourcePoolMetadataProvider> metadataProviders)
public void afterPropertiesSet()
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean@Bean
@ConditionalOnMissingBean(name={"dbHealthIndicator","dbHealthContributor"})
public org.springframework.boot.actuate.health.HealthContributor dbHealthContributor(java.util.Map<java.lang.String,javax.sql.DataSource> dataSources,
DataSourceHealthIndicatorProperties dataSourceHealthIndicatorProperties)