"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "moskito-webui/src/main/java/net/anotheria/moskito/webui/threshold/resource/ThresholdResource.java" between
moskito-moskito-2.9.3.tar.gz and moskito-moskito-2.10.0.tar.gz

About: MoSKito (Monitoring System Kit) is a framework for java application monitoring. Sources.

ThresholdResource.java  (moskito-moskito-2.9.3):ThresholdResource.java  (moskito-moskito-2.10.0)
package net.anotheria.moskito.webui.threshold.resource; package net.anotheria.moskito.webui.threshold.resource;
import io.swagger.v3.oas.annotations.servers.Server;
import net.anotheria.anoplass.api.APIException; import net.anotheria.anoplass.api.APIException;
import net.anotheria.moskito.webui.shared.resource.AbstractResource; import net.anotheria.moskito.webui.shared.resource.AbstractResource;
import net.anotheria.moskito.webui.shared.resource.ReplyObject; import net.anotheria.moskito.webui.shared.resource.ReplyObject;
import net.anotheria.moskito.webui.threshold.api.ThresholdPO; import net.anotheria.moskito.webui.threshold.api.ThresholdPO;
import javax.ws.rs.DELETE; import javax.ws.rs.DELETE;
import javax.ws.rs.GET; import javax.ws.rs.GET;
import javax.ws.rs.POST; import javax.ws.rs.POST;
import javax.ws.rs.Path; import javax.ws.rs.Path;
import javax.ws.rs.PathParam; import javax.ws.rs.PathParam;
import javax.ws.rs.WebApplicationException; import javax.ws.rs.WebApplicationException;
/** /**
* This resource handles thresholds in the moskito-inspect rest interface. * This resource handles thresholds in the moskito-inspect rest interface.
* *
* @author lrosenberg * @author lrosenberg
* @since 11.02.13 18:24 * @since 11.02.13 18:24
*/ */
@Path("/thresholds") @Path("/thresholds")
@Server(url = "/moskito-inspect-rest/") //@Server(url = "/moskito-inspect-rest/")
public class ThresholdResource extends AbstractResource{ public class ThresholdResource extends AbstractResource{
@GET @GET
public ReplyObject getThresholds(){ public ReplyObject getThresholds(){
try{ try{
ReplyObject ret = ReplyObject.success(); ReplyObject ret = ReplyObject.success();
ret.addResult("statuses", getThresholdAPI().getThresholdS tatuses()); ret.addResult("statuses", getThresholdAPI().getThresholdS tatuses());
ret.addResult("definitions", getThresholdAPI().getThresho ldDefinitions()); ret.addResult("definitions", getThresholdAPI().getThresho ldDefinitions());
return ret; return ret;
}catch(APIException e){ }catch(APIException e){
 End of changes. 2 change blocks. 
2 lines changed or deleted 1 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)