Class GcpStackdriverMetricsAutoConfiguration

java.lang.Object
com.google.cloud.spring.autoconfigure.metrics.GcpStackdriverMetricsAutoConfiguration

@AutoConfiguration @AutoConfigureBefore(org.springframework.boot.actuate.autoconfigure.metrics.export.stackdriver.StackdriverMetricsExportAutoConfiguration.class) @AutoConfigureAfter(org.springframework.boot.actuate.autoconfigure.metrics.MetricsAutoConfiguration.class) @ConditionalOnClass(io.micrometer.stackdriver.StackdriverMeterRegistry.class) @ConditionalOnBean(io.micrometer.core.instrument.Clock.class) @ConditionalOnEnabledMetricsExport("stackdriver") @EnableConfigurationProperties({GcpMetricsProperties.class,org.springframework.boot.actuate.autoconfigure.metrics.export.stackdriver.StackdriverProperties.class}) @ConditionalOnProperty(value="spring.cloud.gcp.metrics.enabled", matchIfMissing=true, havingValue="true") public class GcpStackdriverMetricsAutoConfiguration extends Object
Provides auto-detection for `project-id` and `credentials`.
Since:
1.2.4
  • Constructor Details

    • GcpStackdriverMetricsAutoConfiguration

      public GcpStackdriverMetricsAutoConfiguration(GcpMetricsProperties gcpMetricsProperties, org.springframework.boot.actuate.autoconfigure.metrics.export.stackdriver.StackdriverProperties stackdriverProperties, GcpProjectIdProvider gcpProjectIdProvider, com.google.api.gax.core.CredentialsProvider credentialsProvider) throws IOException
      Throws:
      IOException
  • Method Details

    • stackdriverConfig

      @Bean @ConditionalOnMissingBean public io.micrometer.stackdriver.StackdriverConfig stackdriverConfig()
    • metricServiceSettings

      @Bean @ConditionalOnMissingBean public com.google.cloud.monitoring.v3.MetricServiceSettings metricServiceSettings() throws IOException
      Throws:
      IOException
    • stackdriverMeterRegistry

      @Bean @ConditionalOnMissingBean public io.micrometer.stackdriver.StackdriverMeterRegistry stackdriverMeterRegistry(io.micrometer.stackdriver.StackdriverConfig stackdriverConfig, io.micrometer.core.instrument.Clock clock, com.google.cloud.monitoring.v3.MetricServiceSettings metricServiceSettings)