Hi every one,
i developpe a gadget which have to retreive data from a rest service.
i want show the result of my rest service before communicate it with the gadget.
atlassian-plugin.xml :
--------------------------
<rest key="helloWorldRest" path="/helloworld" version="1.0">
<description>Provides hello world services.</description>
</rest>
my rest service:
-------------------
@Path("/")
@Consumes({MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON})
@Produces({MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON})
public class RestHelloWorldService {
@GET
@Path("users")
public Response getUncompletedUsers() {
return Response.ok(new User("Fred","Bloggs")).build();
}
}
class User
-------------
@XmlRootElement
public class User
{
@XmlElement
private String firstName;
@XmlElement
private String lastName;
// This private constructor isn't used by any code, but JAXB requires any
// representation class to have a no-args constructor.
private User() { }
public User(String firstName, String lastName)
{
this.firstName = firstName;
this.lastName = lastName;
}
}
i used this : http://localhost:2990/jira/rest/helloworld/1.0/users
but i had this error :
Etat HTTP 404 - /jira/rest/helloworld/1.0/users
how can display my rest service result ??
Thanks