Search in sources :

Example 1 with SumMetric

use of com.yahoo.metrics.SumMetric in project vespa by vespa-engine.

the class ProgressPrinter method getOkMessageCount.

public long getOkMessageCount(RouteMetricSet metrics) {
    SumMetric sum = (SumMetric) metrics.getMetric("total");
    MetricSet ms = (MetricSet) sum.generateSum();
    if (ms != null) {
        Metric latency = ms.getMetric("latency");
        if (latency != null) {
            return latency.getLongValue("count");
        }
    }
    return 0;
}
Also used : SumMetric(com.yahoo.metrics.SumMetric) Metric(com.yahoo.metrics.Metric) SumMetric(com.yahoo.metrics.SumMetric) MetricSet(com.yahoo.metrics.MetricSet) MessageTypeMetricSet(com.yahoo.clientmetrics.MessageTypeMetricSet) RouteMetricSet(com.yahoo.clientmetrics.RouteMetricSet)

Aggregations

MessageTypeMetricSet (com.yahoo.clientmetrics.MessageTypeMetricSet)1 RouteMetricSet (com.yahoo.clientmetrics.RouteMetricSet)1 Metric (com.yahoo.metrics.Metric)1 MetricSet (com.yahoo.metrics.MetricSet)1 SumMetric (com.yahoo.metrics.SumMetric)1