blob: 8e4e3486a12cd8b1a59bce7d96cd6678d37179e7 [file] [log] [blame]
Pavlin Radoslavov4ef543e2013-05-07 13:36:57 -07001package net.floodlightcontroller.flowcache.web;
2
Pavlin Radoslavov4ef543e2013-05-07 13:36:57 -07003import net.floodlightcontroller.util.FlowId;
HIGUCHI Yutaedf81d72013-06-12 12:06:57 -07004import net.onrc.onos.ofcontroller.flowcache.IFlowService;
Pavlin Radoslavov4ef543e2013-05-07 13:36:57 -07005
6import org.openflow.util.HexString;
7import org.restlet.resource.Get;
8import org.restlet.resource.ServerResource;
9import org.slf4j.Logger;
10import org.slf4j.LoggerFactory;
11
12public class MeasurementGetInstallPathsTimeNsecFlowResource extends ServerResource {
13 protected static Logger log = LoggerFactory.getLogger(MeasurementGetInstallPathsTimeNsecFlowResource.class);
14
15 @Get("json")
16 public Long retrieve() {
17 Long result = null;
18
19 IFlowService flowService =
20 (IFlowService)getContext().getAttributes().
21 get(IFlowService.class.getCanonicalName());
22
23 if (flowService == null) {
24 log.debug("ONOS Flow Service not found");
25 return result;
26 }
27
28 // Extract the arguments
29
30 // Process the request
31 result = flowService.measurementGetInstallPathsTimeNsec();
32
33 log.debug("Measurement Get Install Paths Time (nsec): " + result);
34
35 return result;
36 }
37}