Class HealthCheckMetricsAspect

java.lang.Object
com.netflix.genie.web.aspects.HealthCheckMetricsAspect

public class HealthCheckMetricsAspect extends Object
Aspect around Spring Boot 'HealthIndicator' to publish metrics for status of individual indicator, as well as their turnaround time.
Since:
3.2.4
  • Constructor Details

    • HealthCheckMetricsAspect

      public HealthCheckMetricsAspect(io.micrometer.core.instrument.MeterRegistry registry)
      Autowired constructor.
      Parameters:
      registry - metrics registry
  • Method Details

    • healthIndicatorGetHealth

      public void healthIndicatorGetHealth()
      Pointcut that matches invocations of HealthIndicator::getHealth(..).
    • aroundHealthIndicatorGetHealth

      public org.springframework.boot.actuate.health.Health aroundHealthIndicatorGetHealth(org.aspectj.lang.ProceedingJoinPoint joinPoint) throws Throwable
      Aspect around join point for HealthIndicator::getHealth(..). Measures the turnaround time for the indicator call and publishes it as metric, tagged with indicator class and the status reported.
      Parameters:
      joinPoint - the join point
      Returns:
      health as reported by the indicator
      Throws:
      Throwable - in case of exception in the join point