use of com.codahale.metrics.Counter in project engineblock by engineblock.
the class ExceptionCountMetrics method count.
public void count(Throwable e) {
Counter c = counters.get(e.getClass());
if (c == null) {
synchronized (counters) {
c = counters.computeIfAbsent(e.getClass(), k -> ActivityMetrics.counter(activityDef, "errorcounts." + e.getClass().getSimpleName()));
}
}
c.inc();
}
Aggregations