Class PartialAggregation

java.lang.Object
io.github.resilience4j.core.metrics.PartialAggregation
All Implemented Interfaces:
CumulativeMeasurement, MeasurementData

public class PartialAggregation extends Object
  • Method Details

    • getEpochSecond

      public long getEpochSecond()
    • getTotalDurationInMillis

      public long getTotalDurationInMillis()
      Description copied from interface: MeasurementData
      Returns the total duration of all calls in this measurement.
      Specified by:
      getTotalDurationInMillis in interface MeasurementData
      Returns:
      the total duration of all calls
    • getNumberOfSlowCalls

      public int getNumberOfSlowCalls()
      Description copied from interface: MeasurementData
      Returns the number of calls in this measurement which were slower than a certain threshold.
      Specified by:
      getNumberOfSlowCalls in interface MeasurementData
      Returns:
      the number of calls which were slower than a certain threshold
    • getNumberOfSlowFailedCalls

      public int getNumberOfSlowFailedCalls()
      Description copied from interface: MeasurementData
      Returns the number of failed calls in this measurement which were slower than a certain threshold.
      Specified by:
      getNumberOfSlowFailedCalls in interface MeasurementData
      Returns:
      the number of failed calls which were slower than a certain threshold
    • getNumberOfFailedCalls

      public int getNumberOfFailedCalls()
      Description copied from interface: MeasurementData
      Returns the number of failed calls in this measurement.
      Specified by:
      getNumberOfFailedCalls in interface MeasurementData
      Returns:
      the number of failed calls
    • getNumberOfCalls

      public int getNumberOfCalls()
      Description copied from interface: MeasurementData
      Returns the total number of all calls in this measurement.
      Specified by:
      getNumberOfCalls in interface MeasurementData
      Returns:
      the total number of all calls
    • record

      public void record(long duration, TimeUnit durationUnit, Metrics.Outcome outcome)
      Description copied from interface: CumulativeMeasurement
      Records a call duration and its outcome.
      Specified by:
      record in interface CumulativeMeasurement
      Parameters:
      duration - the call duration
      durationUnit - the time unit of the call duration
      outcome - the outcome of the call