Skip to content

Instantly share code, notes, and snippets.

@KAllan357
Created July 30, 2014 19:20
Show Gist options
  • Save KAllan357/14d6e24980d20287d123 to your computer and use it in GitHub Desktop.
Save KAllan357/14d6e24980d20287d123 to your computer and use it in GitHub Desktop.
package com.riotgames.nexus.rest;
import org.sonatype.sisu.goodies.common.ComponentSupport;
import org.sonatype.sisu.siesta.common.Resource;
import javax.inject.Named;
import javax.inject.Singleton;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.Produces;
import javax.ws.rs.core.Response;
import javax.ws.rs.core.MediaType;
@Named
@Singleton
@Path("hello")
public class HelloWorldResource extends ComponentSupport implements Resource {
@Produces({MediaType.TEXT_PLAIN})
@GET
public Response get() throws Exception {
return Response.ok("hello buddy!").build();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment