java.lang.Object
com.erudika.para.core.metrics.Metrics
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic final class
An auto-closeable class that manages timers for both the overall system as well as specific application. -
Field Summary
Modifier and TypeFieldDescriptionstatic final String
The name of the default system @{link MetricRegistry}. -
Method Summary
Modifier and TypeMethodDescriptionstatic com.codahale.metrics.Counter
Creates a new counter for a particular class and method for a specific application.static String
getClassName
(Class<?> clazz) static Metrics.Context
Instantiate timing of a particular class and method for a specific application.
-
Field Details
-
SYSTEM_METRICS_NAME
The name of the default system @{link MetricRegistry}.- See Also:
-
-
Method Details
-
time
Instantiate timing of a particular class and method for a specific application.- Parameters:
appid
- the application that invoked the requestclazz
- the Class to be timednames
- one or more unique names to identify the timer - usually a method name- Returns:
- a closeable context that encapsulates the timed method
-
counter
Creates a new counter for a particular class and method for a specific application.- Parameters:
appid
- the application that invoked the requestclazz
- the Class to be countednames
- one or more unique names to identify the counter - usually a method name- Returns:
- a counter
-
getClassName
-