I am trying the functionality of servicemix-bean component and following the example where I am setting the response to be sent back to the caller, aka INOUT exchange. As clearly described in the example this can only be done when the exchange is IN/OUT. When the code gets executed I get the exception that the exchange is IN ONLY and therefore this code can not be executed. My question is how do I make sure that the exchange is IN/OUT. Is this configured anywhere
BTW, the input into bean component is jms-consumer component.
Thanks in advance.
The message exchange pattern is determined by the first component accepting or creating the message (e.g. a bc consumer or an internal timer). You cannot change the MEP programmatically.
If you require an InOut MEP, perhaps use a http consumer or cxf consumer as the initial component in your flow.