"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "moskito-webui/src/main/java/net/anotheria/moskito/webui/shared/resource/VersionResource.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.

VersionResource.java  (moskito-moskito-2.9.3):VersionResource.java  (moskito-moskito-2.10.0)
package net.anotheria.moskito.webui.shared.resource; package net.anotheria.moskito.webui.shared.resource;
import io.swagger.v3.oas.annotations.servers.Server;
import net.anotheria.moskito.webui.util.VersionUtil; import net.anotheria.moskito.webui.util.VersionUtil;
import net.anotheria.util.maven.MavenVersion; import net.anotheria.util.maven.MavenVersion;
import javax.servlet.ServletContext; import javax.servlet.ServletContext;
import javax.ws.rs.GET; import javax.ws.rs.GET;
import javax.ws.rs.Path; import javax.ws.rs.Path;
import javax.ws.rs.core.Context; import javax.ws.rs.core.Context;
/** /**
* TODO comment this class * TODO comment this class
* *
* @author lrosenberg * @author lrosenberg
* @since 28.06.15 00:17 * @since 28.06.15 00:17
*/ */
@Path("version") @Path("version")
@Server(url = "/moskito-inspect-rest/") //@Server(url = "/moskito-inspect-rest/")
public class VersionResource extends AbstractResource{ public class VersionResource extends AbstractResource{
@GET @GET
public ReplyObject getVersion(@Context ServletContext context){ public ReplyObject getVersion(@Context ServletContext context){
try{ try{
MavenVersion moskitoVersion = VersionUtil.getWebappLibVer sion(context, "moskito-webui"); MavenVersion moskitoVersion = VersionUtil.getWebappLibVer sion(context, "moskito-webui");
if (moskitoVersion == null) if (moskitoVersion == null)
return ReplyObject.error("Can't read version"); return ReplyObject.error("Can't read version");
return ReplyObject.success("version", moskitoVersion); return ReplyObject.success("version", moskitoVersion);
}catch(Exception any){ }catch(Exception any){
 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)