Examples of DailyGraph


Examples of com.dianping.cat.core.dal.DailyGraph

  public List<DailyGraph> buildDailyGraph() {
    return m_dailyGraphs;
  }

  private DailyGraph buildDailyGraph(ProblemReport problemReport, MachineInfo info) {
    DailyGraph graph = new DailyGraph();
    StringBuilder summary = new StringBuilder();
    StringBuilder detail = new StringBuilder();

    graph.setDomain(problemReport.getDomain());
    graph.setPeriod(problemReport.getStartTime());
    graph.setName(ProblemAnalyzer.ID);
    graph.setIp(info.getIp());
    graph.setType(3);
    graph.setCreationDate(new Date());

    for (java.util.Map.Entry<String, Integer> type : info.getTypesCount().entrySet()) {
      summary.append(type.getKey() + '\t' + type.getValue() + '\n');
    }

    for (java.util.Map.Entry<String, Integer> name : info.getNameCount().entrySet()) {
      detail.append(name.getKey() + '\t' + name.getValue() + '\n');
    }
    graph.setSummaryContent(summary.toString());
    graph.setDetailContent(detail.toString());
    return graph;
  }
View Full Code Here

Examples of com.dianping.cat.core.dal.DailyGraph

  public void visitProblemReport(ProblemReport problemReport) {
    super.visitProblemReport(problemReport);
    m_dailyGraphs.add(buildDailyGraph(problemReport, m_allMachine));

    for (MachineInfo info : m_machines.values()) {
      DailyGraph graph = buildDailyGraph(problemReport, info);

      m_dailyGraphs.add(graph);
    }
  }
View Full Code Here

Examples of com.dianping.cat.core.dal.DailyGraph

    return m_graphs;
  }

  private DailyGraph buildDailyGraph(String ip) {
    DailyGraph graph = new DailyGraph();

    graph.setDomain(m_report.getDomain());
    graph.setPeriod(m_report.getStartTime());
    graph.setName(EventAnalyzer.ID);
    graph.setIp(ip);
    graph.setType(3);
    graph.setCreationDate(new Date());
    return graph;
  }
View Full Code Here

Examples of com.dianping.cat.core.dal.DailyGraph

    return m_graphs;
  }

  private DailyGraph buildDailyGraph(String ip) {
    DailyGraph graph = new DailyGraph();

    graph.setDomain(m_report.getDomain());
    graph.setPeriod(m_report.getStartTime());
    graph.setName(TransactionAnalyzer.ID);
    graph.setIp(ip);
    graph.setType(3);
    graph.setCreationDate(new Date());
    return graph;
  }
View Full Code Here

Examples of com.dianping.cat.core.dal.DailyGraph

    String queryIp = "All".equalsIgnoreCase(ip) == true ? "All" : ip;
    List<DailyGraph> graphs = new ArrayList<DailyGraph>();

    for (long startLong = start.getTime(); startLong < end.getTime(); startLong = startLong + TimeHelper.ONE_DAY) {
      try {
        DailyGraph graph = m_dailyGraphDao.findByDomainNameIpDate(new Date(startLong), queryIp, domain,
              TransactionAnalyzer.ID, DailyGraphEntity.READSET_FULL);
        graphs.add(graph);
      } catch (DalNotFoundException e) {
      } catch (Exception e) {
        Cat.logError(e);
View Full Code Here

Examples of com.dianping.cat.core.dal.DailyGraph

    String queryIp = "All".equalsIgnoreCase(ip) == true ? "All" : ip;
    List<DailyGraph> graphs = new ArrayList<DailyGraph>();

    for (long startLong = start.getTime(); startLong < end.getTime(); startLong = startLong + TimeHelper.ONE_DAY) {
      try {
        DailyGraph graph = m_dailyGraphDao.findByDomainNameIpDate(new Date(startLong), queryIp, domain,
              ProblemAnalyzer.ID, DailyGraphEntity.READSET_FULL);
        graphs.add(graph);
      } catch (DalNotFoundException e) {
      } catch (Exception e) {
        Cat.logError(e);
View Full Code Here

Examples of com.dianping.cat.core.dal.DailyGraph

    String queryIp = "All".equalsIgnoreCase(ip) == true ? "All" : ip;
    List<DailyGraph> graphs = new ArrayList<DailyGraph>();

    for (long startLong = start.getTime(); startLong < end.getTime(); startLong = startLong + TimeHelper.ONE_DAY) {
      try {
        DailyGraph graph = m_dailyGraphDao.findByDomainNameIpDate(new Date(startLong), queryIp, domain,
              EventAnalyzer.ID, DailyGraphEntity.READSET_FULL);
        graphs.add(graph);
      } catch (DalNotFoundException e) {
      } catch (Exception e) {
        Cat.logError(e);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.