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

net.anotheria.moskito.webui.threshold.api.ThresholdAPI Maven / Gradle / Ivy

There is a newer version: 4.0.3
Show newest version
package net.anotheria.moskito.webui.threshold.api;

import net.anotheria.anoplass.api.API;
import net.anotheria.anoplass.api.APIException;
import net.anotheria.anoprise.metafactory.Service;
import net.anotheria.moskito.core.threshold.ThresholdConditionGuard;
import net.anotheria.moskito.core.threshold.ThresholdStatus;
import org.distributeme.annotation.DistributeMe;
import org.distributeme.annotation.FailBy;
import org.distributeme.annotation.SupportService;
import org.distributeme.core.failing.RetryCallOnce;

import java.util.List;

/**
 * API for operations on thresholds.
 *
 * @author lrosenberg
 */
@DistributeMe(agentsSupport=false)
@SupportService
@FailBy(strategyClass=RetryCallOnce.class)
public interface ThresholdAPI extends API, Service {

	List getAlerts() throws APIException;

	void createThreshold(ThresholdPO po) throws APIException;

	List getThresholdStatuses() throws APIException;

	List getThresholdStatuses(String ... names) throws APIException;

	List getThresholdDefinitions() throws APIException;

	void removeThreshold(String id) throws APIException;

	void updateThreshold(String thresholdId, ThresholdPO po) throws APIException;

	ThresholdStatus getWorstStatus() throws APIException;

	/**
	 * Returns threshold definition by id.
	 * @param id
	 * @return
	 * @throws APIException
	 */
	ThresholdDefinitionAO getThresholdDefinition(String id) throws APIException;

	/**
	 * Returns the worst status for the thresholds.
	 * @param thresholdNames
	 * @return
	 * @throws APIException
	 */
	ThresholdStatus getWorstStatus(List thresholdNames) throws APIException;

	List getGuardsForThreshold(String thresholdId) throws APIException;

	/**
	 * Returns all threshold ids which are tied to a specific producer.
	 * @param producerId
	 * @return
	 * @throws APIException
	 */
	List getThresholdIdsTiedToASpecificProducer(String producerId) throws APIException;
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy