I tried today upgrading from Jersey 1.0 to 1.0.1 and 1.0.2-SNAPSHOT -
and got this server side error using 1.0.1 and 1.0.2:
SEVERE: A message body reader for Java type, class net.MyClass, and MIME
media type, application/octet-stream, was not found
Is this a known bug at all? Below is a snippet of basically what I am doing.
*Client snippet*
String id = "someId";
Client client = Client.create();
String resourceUrl = url + "resources/myClasses/" + id;
WebResource r = client.resource(resourceUrl);
MyClass myClass = new MyClass();
myClass.setId(id);
String s = r.put(u);
*Server snippet*
@PUT
@Consumes("application/xml")
@Produces("text/plain")
public void putXml(@PathParam("id")
String id, MyClass content) throws AuthenticationException
{
...
return content.getId();
}
--
Aaron Bruegl