All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.apache.ratis.thirdparty.info.ganglia.gmetric4j.gmetric.GMetricPublisher Maven / Gradle / Ivy

There is a newer version: 1.0.6
Show newest version
package org.apache.ratis.thirdparty.info.ganglia.gmetric4j.gmetric;

import org.apache.ratis.thirdparty.info.ganglia.gmetric4j.Publisher;

public class GMetricPublisher implements Publisher {

	private GMetric gm = null ;
	public GMetricPublisher( GMetric gm ) {
		this.gm = gm ;
	}

	public void publish(String processName, String attributeName, String value,
			GMetricType type, GMetricSlope slope, String units) throws GangliaException {
        publish(processName, attributeName, value, type, slope, 60, 0, units);
	}

	@Override
	public void publish(String processName, String attributeName, String value,
			GMetricType type, GMetricSlope slope, int delay, int lifetime, String units)
			throws GangliaException {
        gm.announce(attributeName, value, type, units, 
        		slope, delay, lifetime, processName);
	}

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy