camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Patrick696 <pwy...@utilidata.com>
Subject Help w/ rest response JSON binding with Jackson
Date Mon, 23 May 2016 14:38:09 GMT
Hi,
I am having a heck of a time figuring out how to return raw json from my
camel rest routes.

If I do something like:
                .marshal(format)
                .convertBodyTo(String.class)
I always get something like:
"{\"status\":200,\"error\":success,\"data\":...}"

If I don't add  .convertBodyTo(String.class), I get the binary inputstream
from my response POJO. 
I just want plain old JSON as a response. 

Any ideas what I am missing here?

Thanks,
Patrick



--
View this message in context: http://camel.465427.n5.nabble.com/Help-w-rest-response-JSON-binding-with-Jackson-tp5782958.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Mime
View raw message