How to send serialized java objects via apache camel?
-
26-09-2019 - |
Question
We use Message or Exchange to set the outbound message . the only method these provide is
exchange.getOut.setBody();
if i do something like setBody(new Object())..it doesn't work
so how do we send java objects via camel exchange.
Solution
And setting a payload as new Object() just means you send an empty object. And if you want serialized objects, then you object must be serializable such as implementing java.io.Serializable
And where do you route the message afterwards?
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow