Have you looked at Type Converters, they can be used to convert the message payload from one type to another
http://camel.apache.org/type-converter.html Bilgin On 14 December 2011 12:41, focaldi <[email protected]> wrote: > Hi everybody, > > I m trying to convert Exchange message to TextMessage format. Beacuse the IX > Agent consume a JMS endpoind and it understands TextMessage format. > > I need to convert message to TextMessage format in jmsqueue. How can I > convert it? > > I can handle "JmsMessage" in P1 processor but I dont know what I should do. > Pls help me? Thanks > P1 processor > ------------------------------------- > Message inMsg = exchange.getOut(); > if (inMsg instanceof JmsMessage) { > JmsMessage jmsMessage = (JmsMessage) inMsg; > } > > My case is : > from(database) -->to(jmsqueue1) > > from(jmsqueue1) -->process(p1)-->to(jmsqueue2) > > to(jmsqueue2) --> IX_AGENT > > > > > -- > View this message in context: > http://camel.465427.n5.nabble.com/How-can-I-convert-Exchange-message-to-TextMessage-tp5074350p5074350.html > Sent from the Camel - Users mailing list archive at Nabble.com.
