I am having a RESTful webservice which was created with Apache WINK
framework(version 1.1.3) with a resource method which is annotated as
@produces("image/jpeg"). From that method, I am building JAX-RS response
with type='image/jpeg' and entity = byte[] (image), like below.
ResponseBuilder.type("image/jpeg");
ResponseBuilder.entity(image);// image is a byte[]
ResponseBuilder.build();
This way of implementation was working fine with java 1.6. Now I am trying
to migrate the java from 1.6 to 1.7. The same code is creating the following
error with java 1.7.
"The system could not find a javax.ws.rs.ext.MessageBodyWriter or a
DataSourceProvider class for the [B type and image/jpeg mediaType. Ensure
that a javax.ws.rs.ext.MessageBodyWriter exists in the JAX-RS application
for the type and media type specified."
Can you please let me know how to resolve this ?
--
View this message in context:
http://apache-wink-users.3471013.n2.nabble.com/Issue-with-java1-7-for-Apache-wink-framework-restful-service-when-setting-response-entity-in-byte-fog-tp7572725.html
Sent from the Apache Wink Users mailing list archive at Nabble.com.