Examples of MetricExpansionConfig


Examples of com.librato.metrics.LibratoReporter.MetricExpansionConfig

      reporter.setSanitizer(getPropertyRef(SANITIZER_REF, Sanitizer.class));
    }

    if (hasProperty(EXPANSION_CONFIG)) {
      String configString = getProperty(EXPANSION_CONFIG).trim().toUpperCase(Locale.ENGLISH);
      final MetricExpansionConfig config;
      if ("ALL".equals(configString)) {
        config = MetricExpansionConfig.ALL;
      }
      else {
        Set<ExpandedMetric> set = new HashSet<ExpandedMetric>();
        String[] expandedMetricStrs = StringUtils.tokenizeToStringArray(configString, ",", true, true);
        for (String expandedMetricStr : expandedMetricStrs) {
          set.add(ExpandedMetric.valueOf(expandedMetricStr));
        }
        config = new MetricExpansionConfig(set);
      }
      reporter.setExpansionConfig(config);
    }
    else if (hasProperty(EXPANSION_CONFIG_REF)) {
      reporter.setExpansionConfig(getProperty(EXPANSION_CONFIG, MetricExpansionConfig.class));
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.