Class SnapshotImpl

java.lang.Object
io.github.resilience4j.core.metrics.SnapshotImpl
All Implemented Interfaces:
Snapshot

public class SnapshotImpl extends Object implements Snapshot
  • Method Details

    • getTotalDuration

      public Duration getTotalDuration()
      Description copied from interface: Snapshot
      Returns the current total duration of all calls.
      Specified by:
      getTotalDuration in interface Snapshot
      Returns:
      the current total duration of all calls
    • getTotalNumberOfSlowCalls

      public int getTotalNumberOfSlowCalls()
      Description copied from interface: Snapshot
      Returns the current number of calls which were slower than a certain threshold.
      Specified by:
      getTotalNumberOfSlowCalls in interface Snapshot
      Returns:
      the current number of calls which were slower than a certain threshold
    • getNumberOfSlowSuccessfulCalls

      public int getNumberOfSlowSuccessfulCalls()
      Description copied from interface: Snapshot
      Returns the current number of successful calls which were slower than a certain threshold.
      Specified by:
      getNumberOfSlowSuccessfulCalls in interface Snapshot
      Returns:
      the current number of successful calls which were slower than a certain threshold
    • getNumberOfSlowFailedCalls

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

      public float getSlowCallRate()
      Description copied from interface: Snapshot
      Returns the current percentage of calls which were slower than a certain threshold.
      Specified by:
      getSlowCallRate in interface Snapshot
      Returns:
      the current percentage of calls which were slower than a certain threshold
    • getNumberOfSuccessfulCalls

      public int getNumberOfSuccessfulCalls()
      Description copied from interface: Snapshot
      Returns the current number of successful calls.
      Specified by:
      getNumberOfSuccessfulCalls in interface Snapshot
      Returns:
      the current number of successful calls
    • getNumberOfFailedCalls

      public int getNumberOfFailedCalls()
      Description copied from interface: Snapshot
      Returns the current number of failed calls.
      Specified by:
      getNumberOfFailedCalls in interface Snapshot
      Returns:
      the current number of failed calls
    • getTotalNumberOfCalls

      public int getTotalNumberOfCalls()
      Description copied from interface: Snapshot
      Returns the current total number of all calls.
      Specified by:
      getTotalNumberOfCalls in interface Snapshot
      Returns:
      the current total number of all calls
    • getFailureRate

      public float getFailureRate()
      Description copied from interface: Snapshot
      Returns the current failure rate in percentage.
      Specified by:
      getFailureRate in interface Snapshot
      Returns:
      the current failure rate in percentage
    • getAverageDuration

      public Duration getAverageDuration()
      Description copied from interface: Snapshot
      Returns the current average duration of all calls.
      Specified by:
      getAverageDuration in interface Snapshot
      Returns:
      the current average duration of all calls
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object