Can anyone help me. I m trying to send a message using camel. Maybe i have the concept wrong.w I would like to send a simple message to an activemq. I have a messageService who was a sendmethode. The proble is i m sending a pojo as message and i would like it to be automaticly transformed to a json string. That's why i tried using camel.
I've defined a rout who point to my send methode and added a marshaller in the rout.
The problem is that camel seems to constantly send a jms message every second. What i would like is that camel converts my output of my message to json when i call the sendMethode.
Here is my rout:
<from uri="bean:messageService?method=sendMessage" />
<marshal>
<json library="Gson"/>
</marshal>
<inOnly uri="activemq:com.pack.checkSynchronicityUrl" />
So when i call the service messageService i want camel to convert the output to json and put it on the queue.
Thanks a lot for your help.