public class WicketMetrics extends Object
Modifier and Type | Class and Description |
---|---|
static class |
WicketMetrics.CounterOperation |
Modifier and Type | Field and Description |
---|---|
static MetaDataKey<com.codahale.metrics.MetricRegistry> |
METRIC_REGISTRY
The key for metrics registry
|
static MetaDataKey<WicketMetricsSettings> |
METRIC_SETTINGS
The key for metrics registry
|
Constructor and Description |
---|
WicketMetrics() |
Modifier and Type | Method and Description |
---|---|
Object |
count(String name,
org.aspectj.lang.ProceedingJoinPoint joinPoint,
WicketMetrics.CounterOperation counterOperation,
Long value)
Creates a count of the given arguments
|
static String |
getFilterName()
Gets the filter name the application should be resolved with
|
static com.codahale.metrics.MetricRegistry |
getMetricRegistry()
Gets the metric registry
|
static WicketMetricsSettings |
getSettings()
Gets the wicket metrics settings
|
Object |
mark(String name,
org.aspectj.lang.ProceedingJoinPoint joinPoint)
Marks the meter with the given name
|
Object |
measureTime(String name,
org.aspectj.lang.ProceedingJoinPoint joinPoint)
Simply measure the time for a @around
|
Object |
measureTime(String name,
org.aspectj.lang.ProceedingJoinPoint joinPoint,
boolean renderClass)
Simply measure the time for a @around
|
String |
renderClassName(org.aspectj.lang.ProceedingJoinPoint joinPoint)
Renders the class name of the given join point
|
static void |
setFilterName(String filterName)
Sets the filter name the application should be resolved with
|
void |
stopQuietly(com.codahale.metrics.Timer.Context context)
Stops the context quietly
|
public static final MetaDataKey<com.codahale.metrics.MetricRegistry> METRIC_REGISTRY
public static final MetaDataKey<WicketMetricsSettings> METRIC_SETTINGS
public Object measureTime(String name, org.aspectj.lang.ProceedingJoinPoint joinPoint) throws Throwable
name
- the name of the timer contextjoinPoint
- the joinPoint to be proceedThrowable
- if there is an exception while executionmeasureTime(String, ProceedingJoinPoint,
boolean)
public Object measureTime(String name, org.aspectj.lang.ProceedingJoinPoint joinPoint, boolean renderClass) throws Throwable
name
- the name of the timer contextjoinPoint
- the joinPoint to be proceedrenderClass
- if the class name should be rendered behind the metric pathThrowable
- if there is an exception while executionpublic void stopQuietly(com.codahale.metrics.Timer.Context context)
context
- the context to stoppublic Object count(String name, org.aspectj.lang.ProceedingJoinPoint joinPoint, WicketMetrics.CounterOperation counterOperation, Long value) throws Throwable
name
- the name of the meter to be markedjoinPoint
- the join pointcounterOperation
- the operationvalue
- the value to update the counterThrowable
public Object mark(String name, org.aspectj.lang.ProceedingJoinPoint joinPoint) throws Throwable
name
- the name of the meter to be markedjoinPoint
- the join pointThrowable
public String renderClassName(org.aspectj.lang.ProceedingJoinPoint joinPoint)
joinPoint
- the join point to get the class ofpublic static com.codahale.metrics.MetricRegistry getMetricRegistry()
public static WicketMetricsSettings getSettings()
public static String getFilterName()
public static void setFilterName(String filterName)
filterName
- the filter nameCopyright © 2006–2022 Apache Software Foundation. All rights reserved.