Class TaggedRetryMetrics

java.lang.Object
io.github.resilience4j.micrometer.tagged.TaggedRetryMetrics
All Implemented Interfaces:
io.micrometer.core.instrument.binder.MeterBinder

public class TaggedRetryMetrics
extends java.lang.Object
implements io.micrometer.core.instrument.binder.MeterBinder
A micrometer binder that is used to register Retry exposed metrics.
  • Field Summary

    Fields 
    Modifier and Type Field Description
    protected java.util.concurrent.ConcurrentMap<java.lang.String,​java.util.Set<io.micrometer.core.instrument.Meter.Id>> meterIdMap  
    protected RetryMetricNames names  
  • Method Summary

    Modifier and Type Method Description
    protected void addMetrics​(io.micrometer.core.instrument.MeterRegistry meterRegistry, io.github.resilience4j.retry.Retry retry)  
    void bindTo​(io.micrometer.core.instrument.MeterRegistry registry)  
    static TaggedRetryMetrics ofRetryRegistry​(io.github.resilience4j.micrometer.tagged.AbstractRetryMetrics.MetricNames names, io.github.resilience4j.retry.RetryRegistry retryRegistry)
    static TaggedRetryMetrics ofRetryRegistry​(RetryMetricNames names, io.github.resilience4j.retry.RetryRegistry retryRegistry)
    Creates a new binder that uses given registry as source of retries.
    static TaggedRetryMetrics ofRetryRegistry​(io.github.resilience4j.retry.RetryRegistry retryRegistry)
    Creates a new binder that uses given registry as source of retries.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • names

      protected final RetryMetricNames names
    • meterIdMap

      protected java.util.concurrent.ConcurrentMap<java.lang.String,​java.util.Set<io.micrometer.core.instrument.Meter.Id>> meterIdMap
  • Method Details

    • ofRetryRegistry

      public static TaggedRetryMetrics ofRetryRegistry​(io.github.resilience4j.retry.RetryRegistry retryRegistry)
      Creates a new binder that uses given registry as source of retries.
      Parameters:
      retryRegistry - the source of retries
      Returns:
      The TaggedRetryMetrics instance.
    • ofRetryRegistry

      public static TaggedRetryMetrics ofRetryRegistry​(RetryMetricNames names, io.github.resilience4j.retry.RetryRegistry retryRegistry)
      Creates a new binder that uses given registry as source of retries.
      Parameters:
      names - custom metric names
      retryRegistry - the source of retries
      Returns:
      The TaggedRetryMetrics instance.
    • ofRetryRegistry

      @Deprecated public static TaggedRetryMetrics ofRetryRegistry​(io.github.resilience4j.micrometer.tagged.AbstractRetryMetrics.MetricNames names, io.github.resilience4j.retry.RetryRegistry retryRegistry)
      Creates a new binder that uses given registry as source of retries.
      Parameters:
      names - custom metric names
      retryRegistry - the source of retries
      Returns:
      The TaggedRetryMetrics instance.
    • bindTo

      public void bindTo​(io.micrometer.core.instrument.MeterRegistry registry)
      Specified by:
      bindTo in interface io.micrometer.core.instrument.binder.MeterBinder
    • addMetrics

      protected void addMetrics​(io.micrometer.core.instrument.MeterRegistry meterRegistry, io.github.resilience4j.retry.Retry retry)