Class MetricsConfiguration

  • All Implemented Interfaces:
    com.ryantenney.metrics.spring.config.annotation.MetricsConfigurer, org.springframework.beans.factory.DisposableBean, org.springframework.boot.web.servlet.ServletContextInitializer

    @Configuration
    @EnableMetrics(proxyTargetClass=true)
    public class MetricsConfiguration
    extends com.ryantenney.metrics.spring.config.annotation.MetricsConfigurerAdapter
    implements org.springframework.boot.web.servlet.ServletContextInitializer
    • Constructor Detail

      • MetricsConfiguration

        public MetricsConfiguration​(io.github.jhipster.config.JHipsterProperties jHipsterProperties)
    • Method Detail

      • setHikariDataSource

        @Autowired(required=false)
        public void setHikariDataSource​(com.zaxxer.hikari.HikariDataSource hikariDataSource)
      • getMetricRegistry

        @Bean
        public com.codahale.metrics.MetricRegistry getMetricRegistry()
        Specified by:
        getMetricRegistry in interface com.ryantenney.metrics.spring.config.annotation.MetricsConfigurer
        Overrides:
        getMetricRegistry in class com.ryantenney.metrics.spring.config.annotation.MetricsConfigurerAdapter
      • getHealthCheckRegistry

        @Bean
        public com.codahale.metrics.health.HealthCheckRegistry getHealthCheckRegistry()
        Specified by:
        getHealthCheckRegistry in interface com.ryantenney.metrics.spring.config.annotation.MetricsConfigurer
        Overrides:
        getHealthCheckRegistry in class com.ryantenney.metrics.spring.config.annotation.MetricsConfigurerAdapter
      • init

        @PostConstruct
        public void init()
      • onStartup

        public void onStartup​(javax.servlet.ServletContext servletContext)
        Specified by:
        onStartup in interface org.springframework.boot.web.servlet.ServletContextInitializer