camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claus Ibsen <claus.ib...@gmail.com>
Subject Re: Why Json Marshal to activemq is BytesMessage?
Date Tue, 28 Jan 2014 12:15:53 GMT
I would assume the json data format marshall into a byte array / byte
input stream. And therefore its mapped as bytes when sent to JMS.


On Tue, Jan 28, 2014 at 10:07 AM, Rural Hunter <ruralhunter@gmail.com> wrote:
> Hi,
>
> I'm using camel 2.12.2 with this route:
> ....marshal().json(JsonLibrary.Gson).to("activemq:queue:completed")
>
> When I process the message in other application, I found the message in the
> queue is BytesMessage instead of expected TextMessage. I have to force it to
> TextMessage by adding parameter "?jmsMessageType=Text" in the queue name. Is
> that a correct behavior to store json as BytesMessage?



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen
Make your Camel applications look hawt, try: http://hawt.io

Mime
View raw message