Examples of AvroFlumeReport


Examples of com.cloudera.flume.reporter.server.avro.AvroFlumeReport

    ReportManager reportManager = ReportManager.get();
    Map<String, Reportable> reports = reportManager.getReportables();

    for (Entry<String, Reportable> e : reports.entrySet()) {
      AvroFlumeReport report = reportToAvro(e.getValue().getMetrics());
      retMap.put(e.getKey(), report);
    }
    return retMap;
  }
View Full Code Here

Examples of com.cloudera.flume.reporter.server.avro.AvroFlumeReport

      default:
        LOG.warn("Unknown type " + t);
      }
    }

    AvroFlumeReport out = new AvroFlumeReport();
    Map<CharSequence, CharSequence> stringMapUtf = new HashMap<CharSequence, CharSequence>();
    for (String s : stringMap.keySet()) {
      stringMapUtf.put(s, stringMap.get(s));
    }
View Full Code Here

Examples of com.cloudera.flume.reporter.server.avro.AvroFlumeReport

    @Override
    public Void putReports(Map<CharSequence, AvroFlumeReport> reports)
        throws AvroRemoteException {
      Log.info("putReports called at server on " + this.server.getPort());
      assertEquals(1, reports.size());
      AvroFlumeReport report = reports.get("reportKey");
      assertNotNull(report);
      Map<CharSequence, Long> longMetrics = report.longMetrics;
      assertEquals(2, longMetrics.size());

      assertEquals(Long.MIN_VALUE, ((Long) longMetrics.get("long1"))
View Full Code Here

Examples of com.cloudera.flume.reporter.server.avro.AvroFlumeReport

    }

    Map<CharSequence, AvroFlumeReport> ret = avroClient.getAllReports();
    assertTrue(ret.size() == 1);

    AvroFlumeReport rep = ret.get(new Utf8("reportable1"));

    assertNotNull("Report 'reportable1' not found", rep);
    assertTrue("Expected exactly one double metric",
        rep.doubleMetrics.size() == 1);
    assertTrue("Expected double metric to be equal to 0.5", rep.doubleMetrics
View Full Code Here

Examples of com.cloudera.flume.reporter.server.avro.AvroFlumeReport

    } catch (Exception e) {
      throw new IOException("Failed to open AvroReportServer at " + PORT
          + " : " + e.getMessage());
    }

    AvroFlumeReport rep = avroClient.getReportByName("reportable1");

    assertNotNull("Report 'reportable1' not found", rep);
    assertTrue("Expected exactly one double metric",
        rep.doubleMetrics.size() == 1);
    assertTrue("Expected double metric to be equal to 0.5", rep.doubleMetrics
View Full Code Here

Examples of com.cloudera.flume.reporter.server.avro.AvroFlumeReport

    ReportManager reportManager = ReportManager.get();
    Map<String, Reportable> reports = reportManager.getReportables();

    for (Entry<String, Reportable> e : reports.entrySet()) {
      AvroFlumeReport report = reportToAvro(e.getValue().getMetrics());
      retMap.put(e.getKey(), report);
    }
    return retMap;
  }
View Full Code Here

Examples of com.cloudera.flume.reporter.server.avro.AvroFlumeReport

      default:
        LOG.warn("Unknown type " + t);
      }
    }

    AvroFlumeReport out = new AvroFlumeReport();
    Map<CharSequence, CharSequence> stringMapUtf = new HashMap<CharSequence, CharSequence>();
    for (String s : stringMap.keySet()) {
      stringMapUtf.put(s, stringMap.get(s));
    }
View Full Code Here

Examples of com.cloudera.flume.reporter.server.avro.AvroFlumeReport

    }

    Map<CharSequence, AvroFlumeReport> ret = avroClient.getAllReports();
    assertTrue(ret.size() == 1);

    AvroFlumeReport rep = ret.get(new Utf8("reportable1"));

    assertNotNull("Report 'reportable1' not found", rep);
    assertTrue("Expected exactly one double metric",
        rep.doubleMetrics.size() == 1);
    assertTrue("Expected double metric to be equal to 0.5", rep.doubleMetrics
View Full Code Here

Examples of com.cloudera.flume.reporter.server.avro.AvroFlumeReport

    } catch (Exception e) {
      throw new IOException("Failed to open AvroReportServer at " + PORT
          + " : " + e.getMessage());
    }

    AvroFlumeReport rep = avroClient.getReportByName("reportable1");

    assertNotNull("Report 'reportable1' not found", rep);
    assertTrue("Expected exactly one double metric",
        rep.doubleMetrics.size() == 1);
    assertTrue("Expected double metric to be equal to 0.5", rep.doubleMetrics
View Full Code Here

Examples of com.cloudera.flume.reporter.server.avro.AvroFlumeReport

    @Override
    public Void putReports(Map<CharSequence, AvroFlumeReport> reports)
        throws AvroRemoteException {
      Log.info("putReports called at server on " + this.server.getPort());
      assertEquals(1, reports.size());
      AvroFlumeReport report = reports.get("reportKey");
      assertNotNull(report);
      Map<CharSequence, Long> longMetrics = report.longMetrics;
      assertEquals(2, longMetrics.size());

      assertEquals(Long.MIN_VALUE,
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.