mirror of
https://github.com/ebean-orm/ebean.git
synced 2024-04-21 10:51:47 +00:00
Remove io.ebean.meta.MetricType as it is unnecessary (#1923)
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
package io.ebeaninternal.server.profile;
|
||||
|
||||
import io.ebean.meta.MetricType;
|
||||
import io.ebean.meta.MetricVisitor;
|
||||
import io.ebean.metric.TimedMetricMap;
|
||||
|
||||
@@ -8,14 +7,11 @@ import java.util.concurrent.ConcurrentHashMap;
|
||||
|
||||
class DTimedMetricMap implements TimedMetricMap {
|
||||
|
||||
private final MetricType metricType;
|
||||
|
||||
private final String name;
|
||||
|
||||
private final ConcurrentHashMap<String, DTimedMetric> map = new ConcurrentHashMap<>();
|
||||
|
||||
DTimedMetricMap(MetricType metricType, String name) {
|
||||
this.metricType = metricType;
|
||||
DTimedMetricMap(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
@@ -26,7 +22,7 @@ class DTimedMetricMap implements TimedMetricMap {
|
||||
|
||||
@Override
|
||||
public void add(String key, long exeMicros) {
|
||||
map.computeIfAbsent(key, (k) -> new DTimedMetric(metricType, name + key)).add(exeMicros);
|
||||
map.computeIfAbsent(key, (k) -> new DTimedMetric(name + key)).add(exeMicros);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user