i know that there are so many question about this...but they didn't fit for me, i tryed to reinstall maven (because creating a new maven project or convert an existing dynamic web project gave me error to pom.xml) in eclipse but it keep saying that is already installed...so i'm questioning about the fact that is it possible to get json from a rest web service without using maven? i already get string/xml/html from my ws, now i've created a new class like this:
@Path("/jsonServices")
public class JerseyRestService {
@GET
@Path("/print/{name}")
@Produces(MediaType.APPLICATION_JSON)
public Student produceJSON( @PathParam("name") String name ) {
Student st = new Student(name, "Diaz",22,1);
return st;
}
i've referenced also those libraries:jackson-all-1.9.9.jar jersey-media-moxy-2.3.jar jersey-entity-filtering-2.21.jar genson-1.3.jar but the error it gave me is: MessageBodyWriter not found for media type=application/json
and the browser:
HTTP Status 500 - Internal Server Error
type Status report
message Internal Server Error
description The server encountered an internal error that prevented it from fulfilling this request.