@Configuration(proxyBeanMethods=false) @ConditionalOnClass(value={org.springframework.boot.actuate.health.HealthIndicator.class,com.google.cloud.monitoring.v3.MetricServiceClient.class}) @ConditionalOnEnabledHealthIndicator(value="pubsub-subscriber") @ConditionalOnProperty(value={"spring.cloud.gcp.pubsub.health.lagThreshold","spring.cloud.gcp.pubsub.health.backlogThreshold"}) @AutoConfigureBefore(value=GcpPubSubAutoConfiguration.class) @EnableConfigurationProperties(value=GcpPubSubProperties.class) public class PubSubSubscriptionHealthIndicatorAutoConfiguration extends org.springframework.boot.actuate.autoconfigure.health.CompositeHealthContributorConfiguration<PubSubHealthIndicator,PubSubTemplate>
Constructor and Description |
---|
PubSubSubscriptionHealthIndicatorAutoConfiguration(GcpPubSubProperties gcpPubSubProperties,
GcpProjectIdProvider projectIdProvider) |
Modifier and Type | Method and Description |
---|---|
com.google.api.gax.core.ExecutorProvider |
healthCheckExecutorProvider(org.springframework.scheduling.concurrent.ThreadPoolTaskScheduler scheduler) |
HealthTrackerRegistry |
healthTrackerRegistry(MetricServiceClient metricServiceClient,
com.google.api.gax.core.ExecutorProvider executorProvider) |
MetricServiceClient |
metricServiceClient() |
org.springframework.scheduling.concurrent.ThreadPoolTaskScheduler |
pubSubHealthThreadPool() |
PubSubSubscriptionHealthIndicator |
pubSubSubscriptionHealthIndicator(HealthTrackerRegistry healthTrackerRegistry) |
createComposite
public PubSubSubscriptionHealthIndicatorAutoConfiguration(GcpPubSubProperties gcpPubSubProperties, GcpProjectIdProvider projectIdProvider)
@Bean @ConditionalOnMissingBean public MetricServiceClient metricServiceClient() throws IOException
IOException
@Bean @ConditionalOnMissingBean(name="pubSubHealthThreadPool") public org.springframework.scheduling.concurrent.ThreadPoolTaskScheduler pubSubHealthThreadPool()
@Bean @ConditionalOnMissingBean(name="healthCheckExecutorProvider") public com.google.api.gax.core.ExecutorProvider healthCheckExecutorProvider(@Qualifier(value="pubSubHealthThreadPool") org.springframework.scheduling.concurrent.ThreadPoolTaskScheduler scheduler)
@Bean @ConditionalOnMissingBean(name="healthTrackerRegistry") public HealthTrackerRegistry healthTrackerRegistry(MetricServiceClient metricServiceClient, @Qualifier(value="healthCheckExecutorProvider") com.google.api.gax.core.ExecutorProvider executorProvider)
@Bean @ConditionalOnMissingBean(name="pubSubSubscriptionHealthIndicator") public PubSubSubscriptionHealthIndicator pubSubSubscriptionHealthIndicator(HealthTrackerRegistry healthTrackerRegistry)
Copyright © 2021. All rights reserved.