|
From: Sean D. <sea...@gm...> - 2015-10-09 17:12:16
|
There seems to be very little info online about this but I'm guessing most
people here know that if you send a String value in the body of a REST call
to RestEasy, Jackson complains.
One of our other devs made a JsonStringProvider which seems super simple
(it's readable/writable if it's a String _and_ the type is Json) and it
uses a standard ObjectMapper to read/write the value/stream.
In RE 3.0.11, it seems to work fine in our unit tests - ie. we can makes
calls with Strings and things just work - both writeTo and readFrom methods
get called. But in later versions (3.0.13 & 3.0.14), only the writeTo
method gets hit and Jackson complains, unless we double quote the strings
("\"message\""). Most of our code is the same in both places with the
exception of moving from the deprecated way of creating proxies to the
new/recommended way.
Any ideas? Is it maybe a classpath issue? Or a different way the provider
needs to be registered? Or.... ?
Thanks.
|