Examples of GMetricType


Examples of info.ganglia.gmetric4j.gmetric.GMetricType

    private void reportGauge(String name, Gauge gauge) {
        final String sanitizedName = escapeSlashes(name);
        final String group = group(name);
        final Object obj = gauge.getValue();
        final String value = String.valueOf(obj);
        final GMetricType type = detectType(obj);
        try {
            announce(name(prefix, sanitizedName), group, value, type, "");
        } catch (GangliaException e) {
            LOGGER.warn("Unable to report gauge {}", name, e);
        }
View Full Code Here

Examples of info.ganglia.gmetric4j.gmetric.GMetricType

    String units = selectParameterFromNode(attr, "units", "");
    String pname = selectParameterFromNode(attr, "pname", "");
    String slope = selectParameterFromNode(attr, "slope", "");
    String dMax = selectParameterFromNode(attr, "dmax", mBeanDMax);
    String type = selectParameterFromNode(attr, "type", "");
    GMetricType gType = GMetricType.valueOf(type.toUpperCase());
    GMetricSlope gSlope = GMetricSlope.valueOf(slope.toUpperCase());
    int dMaxInt = parseDMax(dMax);
    String metricName = buildMetricName(processName, mBeanName,
        mBeanPublishName, name, pname);
View Full Code Here

Examples of info.ganglia.gmetric4j.gmetric.GMetricType

    for (final Result result : results) {
      if (result.getValues() != null) {
        for (final Map.Entry<String, Object> resultValue : result.getValues().entrySet()) {
          final String name = KeyUtils.getKeyString(query, result, resultValue, getTypeNames());
          final String value = resultValue.getValue().toString();
          GMetricType dataType = getType(resultValue.getValue());
          log.debug("Sending Ganglia metric {}={} [type={}]", name, value, dataType);
          new GMetric(host, port, addressingMode, ttl, v31, null, spoofedHostName)
              .announce(name, value, dataType, units, slope, tmax, dmax, groupName);
        }
      }
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.