Examples of metrics()


Examples of org.apache.hadoop.metrics2.MetricsRecord.metrics()

      .addCounter(info("S1NumOps", "Number of ops for s1"), 1L)
      .addGauge(info("S1AvgTime", "Average time for s1"), 0.0)
      .metrics(), r.metrics());

    r = recs.get(1);
    assertTrue("NumActiveSinks should be 3", Iterables.contains(r.metrics(),
               new MetricGaugeInt(MsInfo.NumActiveSinks, 3)));
  }

  @Metrics(context="test")
  private static class TestSource {
View Full Code Here

Examples of org.apache.hadoop.metrics2.impl.ExposedMetricsRecordImpl.metrics()

        PhoenixMetricsRecord record = (PhoenixMetricsRecord) invocation.getArguments()[0];
        //validate that we got the right fields in the record
        assertEquals("phoenix.987654", record.name());
        assertEquals("Some generic trace", record.description());
        int count = 0;
        for (PhoenixAbstractMetric metric : record.metrics()) {
          count++;
          //find the matching metric in the list
          boolean found = false;
          for(AbstractMetric expected : metrics){
            if(expected.name().equals(metric.getName())){
View Full Code Here

Examples of org.apache.hama.monitor.MetricsRecord.metrics()

            try {
              MetricsRecord record = (MetricsRecord) future.get();
              if (null != record) {
                if (LOG.isDebugEnabled()) {
                  for (@SuppressWarnings("rawtypes")
                  Metric metric : record.metrics()) {
                    LOG.debug("Metric name:" + metric.name() + " metric value:"
                        + metric.value());
                  }
                }
                repository.put(groom, record);
View Full Code Here

Examples of org.apache.hama.monitor.MetricsRecord.metrics()

            try {
              MetricsRecord record = (MetricsRecord) future.get();
              if (null != record) {
                if (LOG.isDebugEnabled()) {
                  for (@SuppressWarnings("rawtypes")
                  Metric metric : record.metrics()) {
                    LOG.debug("Metric name:" + metric.name() + " metric value:"
                        + metric.value());
                  }
                }
                repository.put(groom, record);
View Full Code Here

Examples of org.apache.hama.monitor.MetricsRecord.metrics()

            try {
              MetricsRecord record = (MetricsRecord) future.get();
              if (null != record) {
                if (LOG.isDebugEnabled()) {
                  for (@SuppressWarnings("rawtypes")
                  Metric metric : record.metrics()) {
                    LOG.debug("Metric name:" + metric.name() + " metric value:"
                        + metric.value());
                  }
                }
                repository.put(groom, record);
View Full Code Here

Examples of org.apache.hama.monitor.MetricsRecord.metrics()

            try {
              MetricsRecord record = (MetricsRecord) future.get();
              if (null != record) {
                if (LOG.isDebugEnabled()) {
                  for (@SuppressWarnings("rawtypes")
                  Metric metric : record.metrics()) {
                    LOG.debug("Metric name:" + metric.name() + " metric value:"
                        + metric.value());
                  }
                }
                repository.put(groom, record);
View Full Code Here

Examples of org.apache.phoenix.metrics.PhoenixMetricsRecord.metrics()

        PhoenixMetricsRecord record = (PhoenixMetricsRecord) invocation.getArguments()[0];
        //validate that we got the right fields in the record
        assertEquals("phoenix.987654", record.name());
        assertEquals("Some generic trace", record.description());
        int count = 0;
        for (PhoenixAbstractMetric metric : record.metrics()) {
          count++;
          //find the matching metric in the list
          boolean found = false;
          for(AbstractMetric expected : metrics){
            if(expected.name().equals(metric.getName())){
View Full Code Here

Examples of org.sonar.api.web.DefaultTab.metrics()

  }

  private void initDefaultTabInfo(final V view) {
    DefaultTab defaultTabAnnotation = AnnotationUtils.getAnnotation(view, DefaultTab.class);
    if (defaultTabAnnotation != null) {
      if (defaultTabAnnotation.metrics().length == 0) {
        isDefaultTab = true;
        defaultForMetrics = new String[0];

      } else {
        isDefaultTab = false;
View Full Code Here

Examples of org.sonar.api.web.DefaultTab.metrics()

        isDefaultTab = true;
        defaultForMetrics = new String[0];

      } else {
        isDefaultTab = false;
        defaultForMetrics = defaultTabAnnotation.metrics();
      }
    }
  }

  private void initResourceLanguage(final V view) {
View Full Code Here

Examples of org.springframework.boot.actuate.endpoint.PublicMetrics.metrics()

  @Test
  public void autoDataSource() {
    load(DataSourceAutoConfiguration.class);
    PublicMetrics bean = this.context.getBean(DataSourcePublicMetrics.class);
    Collection<Metric<?>> metrics = bean.metrics();
    assertMetrics(metrics, "datasource.primary.active", "datasource.primary.usage");
  }

  @Test
  public void multipleDataSources() {
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.