Interface CallTracker
-
- All Known Implementing Classes:
CallTrackerImpl
,NullCallTracker
public interface CallTracker
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interface
CallTracker.CallStats
-
Field Summary
Fields Modifier and Type Field Description static java.lang.Exception
GENERIC_EXCEPTION
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description static CallTracker
create()
double[]
getAverageConcurrency()
CallTracker.CallStats
getCallStats()
long
getCurrentCallCountTotal()
int
getCurrentConcurrency()
long
getCurrentErrorCountTotal()
long
getCurrentStartCountTotal()
long[]
getErrorCount()
int[]
getErrorFrequency()
long
getLastResetTime()
int[]
getMaxConcurrency()
long[]
getStartCount()
int[]
getStartFrequency()
long
getTimeSinceLastStartCall()
static CallTracker
nullTracker()
void
reset()
default CallCompletion
startCall()
CallCompletion
startCall(long startTimeNanos)
default void
trackCall(long duration)
default void
trackCall(long duration, java.util.concurrent.TimeUnit timeUnit)
default void
trackCallWithError(long duration)
default void
trackCallWithError(long duration, java.lang.Throwable throwable)
default void
trackCallWithError(long duration, java.util.concurrent.TimeUnit timeUnit)
void
trackCallWithError(long duration, java.util.concurrent.TimeUnit timeUnit, java.lang.Throwable throwable)
-
-
-
Method Detail
-
startCall
@Nonnull @CheckReturnValue default CallCompletion startCall()
-
startCall
@Nonnull @CheckReturnValue CallCompletion startCall(@Nonnegative long startTimeNanos)
-
trackCall
default void trackCall(long duration)
-
trackCall
default void trackCall(long duration, @Nonnull java.util.concurrent.TimeUnit timeUnit)
-
trackCallWithError
default void trackCallWithError(long duration)
-
trackCallWithError
default void trackCallWithError(long duration, @Nonnull java.util.concurrent.TimeUnit timeUnit)
-
trackCallWithError
default void trackCallWithError(long duration, java.lang.Throwable throwable)
-
trackCallWithError
void trackCallWithError(long duration, @Nonnull java.util.concurrent.TimeUnit timeUnit, java.lang.Throwable throwable)
-
getCurrentStartCountTotal
long getCurrentStartCountTotal()
-
getCurrentCallCountTotal
long getCurrentCallCountTotal()
-
getCurrentErrorCountTotal
long getCurrentErrorCountTotal()
-
getCurrentConcurrency
int getCurrentConcurrency()
-
getAverageConcurrency
@Nonnull @CheckReturnValue double[] getAverageConcurrency()
-
getMaxConcurrency
@Nonnull @CheckReturnValue int[] getMaxConcurrency()
-
getStartFrequency
@Nonnull @CheckReturnValue int[] getStartFrequency()
-
getStartCount
@Nonnull @CheckReturnValue long[] getStartCount()
-
getErrorFrequency
@Nonnull @CheckReturnValue int[] getErrorFrequency()
-
getErrorCount
@Nonnull @CheckReturnValue long[] getErrorCount()
-
getCallStats
@Nonnull @CheckReturnValue CallTracker.CallStats getCallStats()
-
reset
void reset()
-
getLastResetTime
long getLastResetTime()
-
getTimeSinceLastStartCall
long getTimeSinceLastStartCall()
-
create
static CallTracker create()
-
nullTracker
static CallTracker nullTracker()
-
-