MessageBodyWriter not found for media type=application/json
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I am facing issues while consuming JAX-RS services as JSON. Below I have added my code. This is my service class: //Sets the path to base URL + /hello @Path("/hello") @Consumes(MediaType.APPLICATION_JSON) @Produces(MediaType.APPLICATION_JSON) public class Hello { @GET @Produces("application/json") public Student getStudent() { Student s = new Student(); s.first_name = "Test First Name !!!"; s.last_name = "Test Last Name!!!"; return s; } Student class which I am trying to get from service: @XmlRootElement public class Student implements