hi
getting error
[org.glassfish.jersey.message.internal.WriterInterceptorExecutor] [[
MessageBodyWriter not found for media type=application/json, type=class
java.util.HashMap, genericType=class java.util.HashMap.]]
added on pom.xml
<dependency>
<groupId>org.glassfish.jersey.media</groupId>
<artifactId>jersey-media-moxy</artifactId>
<version>2.22.2</version>
</dependency>
also added in
public class MainRsConfig extends ResourceConfig {
register(MvcFeature.class);
...
code
@POST
@Path("w2ui")
@Consumes(MediaType.APPLICATION_JSON)
@Produces(MediaType.APPLICATION_JSON)
public Response w2uiCrudAccount(FormCommand command) {
Map<String, String> res = Maps.newHashMap();
res.put("status", "success");
return Response.status(Response.Status.CREATED).entity(res).build();
}
for pojo getting the same error, and for
@Produces(MediaType.APPLICATION_XML) too
that`s wrong ?
thanks
--
View this message in context: http://jersey.576304.n2.nabble.com/moxy-messagebodywriter-not-found-for-media-type-application-json-again-tp7583669.html
Sent from the Jersey mailing list archive at Nabble.com.