Package com.alibaba.jstorm.ui.model

Examples of com.alibaba.jstorm.ui.model.ClusterSumm


    String nimbustime = StatBuckets.prettyUptimeStr(summ
        .get_nimbus_uptime_secs());

    List<ClusterSumm> clusumms = new ArrayList<ClusterSumm>();

    ClusterSumm clusterSumm = new ClusterSumm();
    String master = client.getMasterHost();
    clusterSumm.setNimbusHostname(master);
    if (master.contains(":")) {
      clusterSumm.setNimbusIp(NetWorkUtils.host2Ip(master.substring(0,
          master.indexOf(":"))));
    } else {
      clusterSumm.setNimbusIp(NetWorkUtils.host2Ip(master));
    }
    int port = ConfigExtension.getNimbusDeamonHttpserverPort(conf);
    clusterSumm.setNimbusLogPort(String.valueOf(port));
    clusterSumm.setNimbusUptime(nimbustime);
    clusterSumm.setSupervisorNum(String.valueOf(supSize));
    clusterSumm.setRunningTaskNum(String.valueOf(totalTasks));

    clusterSumm.setTotalPortSlotNum(String.valueOf(totalPortSlots));
    clusterSumm.setUsedPortSlotNum(String.valueOf(usePortSlots));
    clusterSumm.setFreePortSlotNum(String.valueOf(freePortSlots));
   
    clusterSumm.setVersion(summ.get_version());

    clusumms.add(clusterSumm);
    return clusumms;
  }
View Full Code Here

TOP

Related Classes of com.alibaba.jstorm.ui.model.ClusterSumm

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.