@Override
  @LogMessageDoc(
      level = "INFO",
      message = "Packet processing time threshold for warning" + " set to {time} ms.",
      explanation =
          "Performance monitoring will log a warning if "
              + "packet processing time exceeds the configured threshold")
  public void startUp(FloodlightModuleContext context) {
    // Add our REST API
    restApi.addRestletRoutable(new PerfWebRoutable());

    // TODO - Alex - change this to a config option
    ptWarningThresholdInNano =
        Long.parseLong(
                System.getProperty("net.floodlightcontroller.core.PTWarningThresholdInMilli", "0"))
            * 1000000;
    if (ptWarningThresholdInNano > 0) {
      logger.info(
          "Packet processing time threshold for warning" + " set to {} ms.",
          ptWarningThresholdInNano / 1000000);
    }
  }
 protected void addRestletRoutable() {
   restApi.addRestletRoutable(new TopologyWebRoutable());
 }
Esempio n. 3
0
 @Override
 public void startUp(FloodlightModuleContext context) throws FloodlightModuleException {
   // 启动事宜
   // 向RestAPI中增加Routable类
   restApi.addRestletRoutable(new DebugRoutable());
 }