public final class MetricsUtils extends Object
| Modifier and Type | Method and Description |
|---|---|
static String |
influxName(String measurement,
Map<String,String> tags)
Generate the name for an InfluxDb metric with the given measurement name and tags.
|
static String |
influxName(String measurement,
String field,
Map<String,String> tags)
Generate the name for an InfluxDb metric with the given measurement name, field name, and tags.
|
public static String influxName(String measurement, Map<String,String> tags)
final Timer timer = registry.timer(influxName("Measurement", ImmutableMap.of("action", "restore")));
public static String influxName(String measurement, String field, Map<String,String> tags)
registry.gauge(
influxName("Measurement", "results", ImmutableMap.of("method", "retrieveCats")),
results::size
);
Copyright © 2017. All rights reserved.