Examples of GMonitor


Examples of info.ganglia.GMonitor

 
  @Test
  @SuppressWarnings("unused")
  public void testMetricTypeConstructor() {
    try {
      GMonitor gmon = new GMonitor(MULTICAST_ADDRESS, 30l);
      GMetricInteger testMetric = (GMetricInteger) gmon.createGMetric(host, "Ganglia Test", GMetric.VALUE_TYPE_INT, "count", GMetric.SLOPE_UNSPECIFIED, true);
    } catch (IOException e) {
      e.printStackTrace();
      fail();
    }
  }
View Full Code Here

Examples of info.ganglia.GMonitor

  }
  @Test
  @SuppressWarnings("unused")
  public void testMetricTypeConstructor2() {
    try {
      GMonitor gmon = new GMonitor(MULTICAST_ADDRESS, 30l);
      GMetricString testMetric = (GMetricString) gmon.createGMetric(host, "Ganglia Test", GMetric.VALUE_TYPE_STRING, "count", GMetric.SLOPE_UNSPECIFIED, true);
    } catch (IOException e) {
      e.printStackTrace();
      fail();
    }
  }
View Full Code Here

Examples of info.ganglia.GMonitor

  }
  @Test
  @SuppressWarnings("unused")
  public void testMetricTypeConstructor3() {
    try {
      GMonitor gmon = new GMonitor(MULTICAST_ADDRESS, 30l);
      GMetricFloat testMetric = (GMetricFloat) gmon.createGMetric(host, "Ganglia Test", GMetric.VALUE_TYPE_FLOAT, "count", GMetric.SLOPE_UNSPECIFIED, true);
    } catch (IOException e) {
      e.printStackTrace();
      fail();
    }
  }
View Full Code Here

Examples of info.ganglia.GMonitor

  }
  @Test
  @SuppressWarnings("unused")
  public void testMetricTypeConstructor4() {
    try {
      GMonitor gmon = new GMonitor(MULTICAST_ADDRESS, 30l);
      GMetricDouble testMetric = (GMetricDouble) gmon.createGMetric(host, "Ganglia Test", GMetric.VALUE_TYPE_DOUBLE, "count", GMetric.SLOPE_UNSPECIFIED, true);
    } catch (IOException e) {
      e.printStackTrace();
      fail();
    }
  }
View Full Code Here

Examples of info.ganglia.GMonitor

 
  @Test
  @SuppressWarnings("unused")
  public void testMetricTypeConstructor5() {
    try {
      GMonitor gmon = new GMonitor(MULTICAST_ADDRESS, 30l);
      GMetricInteger testMetric = (GMetricInteger) gmon.createGMetric(host, "Ganglia Test", "INVALID_TYPE", "count", GMetric.SLOPE_UNSPECIFIED, true);
    } catch (IllegalArgumentException e) {
      assertTrue(true);
    } catch (Exception e) {
      fail();
    }
View Full Code Here

Examples of info.ganglia.GMonitor

 
  @Test
  public void testUpdateInt() {
    int value = 10;
    try {
      GMonitor gmon = new GMonitor(MULTICAST_ADDRESS, 30l);
      GMetricInteger testMetric = (GMetricInteger) gmon.createGMetric(host, "Ganglia Test", GMetric.VALUE_TYPE_INT, "count", GMetric.SLOPE_UNSPECIFIED, true);
      testMetric.incrementValue(value);
      testMetric.incrementValue();
      testMetric.setValue(value);
    } catch (IOException e) {
      e.printStackTrace();
View Full Code Here

Examples of info.ganglia.GMonitor

 
  @Test
  public void testUpdateDouble() {
    double value = 10.50;
    try {
      GMonitor gmon = new GMonitor(MULTICAST_ADDRESS, 30l);
      GMetricDouble testMetric = (GMetricDouble) gmon.createGMetric(host, "Ganglia Test", GMetric.VALUE_TYPE_DOUBLE, "count", GMetric.SLOPE_UNSPECIFIED, true);
      testMetric.incrementValue(value);
      testMetric.incrementValue();
      testMetric.setValue(value);
    } catch (IOException e) {
      e.printStackTrace();
View Full Code Here

Examples of info.ganglia.GMonitor

 
  @Test
  public void testUpdateFloat() {
    float value = 10.50f;
    try {
      GMonitor gmon = new GMonitor(MULTICAST_ADDRESS, 30l);
      GMetricFloat testMetric = (GMetricFloat) gmon.createGMetric(host, "Ganglia Test", GMetric.VALUE_TYPE_FLOAT, "count", GMetric.SLOPE_UNSPECIFIED, true);
      testMetric.incrementValue(value);
      testMetric.incrementValue();
      testMetric.setValue(value);
    } catch (IOException e) {
      e.printStackTrace();
View Full Code Here

Examples of info.ganglia.GMonitor

 
  @Test
  public void testUpdateString() {
    String value = "10";
    try {
      GMonitor gmon = new GMonitor(MULTICAST_ADDRESS, 30l);
      GMetricString testMetric = (GMetricString) gmon.createGMetric(host, "Ganglia Test", GMetric.VALUE_TYPE_STRING, "count", GMetric.SLOPE_UNSPECIFIED, true);
      testMetric.setValue(value);
      testMetric.setValue(null);
    } catch (IOException e) {
      e.printStackTrace();
      fail();
View Full Code Here

Examples of info.ganglia.GMonitor

  @Test
  @SuppressWarnings("unused")
  public void testConstructor() {
    try {
      GMonitor gmon = new GMonitor();
      GMetricInteger testMetric = (GMetricInteger) gmon.createGMetric(host, "Ganglia Test", GMetric.VALUE_TYPE_INT, "count", GMetric.SLOPE_UNSPECIFIED, true);
    } catch (IOException e) {
      e.printStackTrace();
      fail();
    }
  }
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.