Search in sources :

Example 1 with ActiveContainerMetrics

use of com.yahoo.jdisc.statistics.ActiveContainerMetrics in project vespa by vespa-engine.

the class MetricUpdaterTest method metrics_are_updated_in_scheduler_cycle.

@Test
public void metrics_are_updated_in_scheduler_cycle() throws InterruptedException {
    Metric metric = mock(Metric.class);
    ActiveContainerMetrics activeContainerMetrics = mock(ActiveContainerMetrics.class);
    new MetricUpdater(new MockScheduler(), metric, activeContainerMetrics);
    verify(activeContainerMetrics, times(1)).emitMetrics(any());
    verify(metric, times(8)).set(anyString(), any(), any());
}
Also used : Metric(com.yahoo.jdisc.Metric) ActiveContainerMetrics(com.yahoo.jdisc.statistics.ActiveContainerMetrics) Test(org.junit.Test)

Aggregations

Metric (com.yahoo.jdisc.Metric)1 ActiveContainerMetrics (com.yahoo.jdisc.statistics.ActiveContainerMetrics)1 Test (org.junit.Test)1