camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claus Ibsen <>
Subject Re: Using String(json) instead of object as body type:
Date Mon, 22 Aug 2011 06:33:08 GMT
On Sat, Aug 20, 2011 at 6:01 PM, Robert Dare <> wrote:
> How does one go about using character/text  body types instead of
> object in Camel routes?  Is it as simple as just setting a string in
> the producer template?
> The ActiveMQ docs indicate that object body types are lowest performance.

Can you provide a bit more details what you want to do? It sounds as
if you want to route messages from Camel to a ActiveMQ queue.
And that you want to use a javax.jms.TextMessage as the JMS message type?

The Camel JMS endpoint has an option to control that, its the
jmsMessageType option. You can read about it here:

Here is an example:

And yes you can also convert the message body to a String type
beforehand as well using the Type Converters


Also there is data format that can convert between types

> Thank you.
> Rob

Claus Ibsen
Twitter: davsclaus, fusenews
Author of Camel in Action:

View raw message