Search in sources :

Example 6 with ControlMetric

use of org.onosproject.cpman.ControlMetric in project onos by opennetworkinglab.

the class ControlPlaneMonitorTest method testUpdateMetricWithId.

private void testUpdateMetricWithId(ControlMetricType cmt, MetricValue mv, DeviceId did) {
    ControlMetric cm = new ControlMetric(cmt, mv);
    monitor.updateMetric(cm, UPDATE_INTERVAL, Optional.of(did));
}
Also used : ControlMetric(org.onosproject.cpman.ControlMetric)

Example 7 with ControlMetric

use of org.onosproject.cpman.ControlMetric in project onos by opennetworkinglab.

the class ControlPlaneMonitorTest method testUpdateMetricWithResource.

private void testUpdateMetricWithResource(ControlMetricType cmt, MetricValue mv, String resourceName) {
    ControlMetric cm = new ControlMetric(cmt, mv);
    monitor.updateMetric(cm, UPDATE_INTERVAL, resourceName);
}
Also used : ControlMetric(org.onosproject.cpman.ControlMetric)

Aggregations

ControlMetric (org.onosproject.cpman.ControlMetric)7 ObjectNode (com.fasterxml.jackson.databind.node.ObjectNode)4 IOException (java.io.IOException)4 Consumes (javax.ws.rs.Consumes)4 POST (javax.ws.rs.POST)4 Path (javax.ws.rs.Path)4 MetricsService (org.onlab.metrics.MetricsService)4 ControlPlaneMonitorService (org.onosproject.cpman.ControlPlaneMonitorService)4 JsonNode (com.fasterxml.jackson.databind.JsonNode)2 ArrayNode (com.fasterxml.jackson.databind.node.ArrayNode)2