Class MicrometerBinderRegistrar

java.lang.Object
com.atlassian.confluence.impl.metrics.MicrometerBinderRegistrar
All Implemented Interfaces:
org.springframework.beans.factory.Aware, org.springframework.context.ApplicationContextAware

public abstract class MicrometerBinderRegistrar extends Object implements org.springframework.context.ApplicationContextAware
Responsible for registering a bunch of standard meters with Micrometer, gathering and publishing metrics on the JVM, Tomcat, Hibernate and others.

This will only happen if ConfluenceMicrometer.isMicrometerEnabled() is true.

Since:
7.0
  • Constructor Details

    • MicrometerBinderRegistrar

      public MicrometerBinderRegistrar(io.micrometer.core.instrument.MeterRegistry meterRegistry, MBeanServer mBeanServer)
  • Method Details

    • setApplicationContext

      public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext) throws org.springframework.beans.BeansException
      Specified by:
      setApplicationContext in interface org.springframework.context.ApplicationContextAware
      Throws:
      org.springframework.beans.BeansException
    • initSystemMetrics

      @PostConstruct public void initSystemMetrics()
    • initTomcatMetrics

      @PostConstruct public void initTomcatMetrics() throws ReflectiveOperationException
      Throws:
      ReflectiveOperationException
    • getSessionFactory

      protected abstract org.hibernate.engine.spi.SessionFactoryImplementor getSessionFactory()
      Spring will subclass this class and provide the Hibernate SessionFactory via this method.