Class StatActionInOut.StatAction

java.lang.Object
com.iohao.net.framework.core.flow.internal.StatActionInOut.StatAction
Enclosing class:
StatActionInOut

public final class StatActionInOut.StatAction extends Object
Per-action statistics record holding execution count, total/average/max time cost, error count, and time range distribution.
Author:
渔民小镇
  • Method Details

    • getTimeRange

      public StatActionInOut.TimeRange getTimeRange(long time)
      Gets the corresponding TimeRange object based on the time cost. If no corresponding time range is found, the last element in the configured List is used.
      Parameters:
      time - Time cost
      Returns:
      TimeRange
    • getAvgTime

      public long getAvgTime()
      Average time cost
      Returns:
      Average time cost
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • getTimeRangeList

      public List<StatActionInOut.TimeRange> getTimeRangeList()
      Time range list
    • getCmdInfo

      public CmdInfo getCmdInfo()
    • getExecuteCount

      public LongAdder getExecuteCount()
      Action execution count statistics
    • getTotalTime

      public LongAdder getTotalTime()
      Total time cost
    • getErrorCount

      public LongAdder getErrorCount()
      Action exception trigger count
    • getMaxTime

      public long getMaxTime()
      Maximum time cost
    • getStatActionInOutToString

      public String getStatActionInOutToString()
      %s, Executed [%s] times, Exceptions [%s] times, Average Time Cost [%d], Maximum Time Cost [%s], Total Time Cost [%s] %s