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: ActiveMQ component and StreamMessage / BlobMessage
Date Thu, 08 Apr 2010 07:28:45 GMT
On Thu, Apr 8, 2010 at 9:27 AM, Norman Maurer
<norman.maurer@googlemail.com> wrote:
> So is this something you would be interesting in ? If so I would try
> to write a patch within the next week.
>

Yeah we love contributions
http://camel.apache.org/contributing.html

You may have to do the AMQ special thing in the activemq-camel
component which is shipped with AMQ (and not Camel).


> Bye,
> Norman
>
>
> 2010/4/7 Norman Maurer <norman.maurer@googlemail.com>:
>> Maybe I should stopping getting on your nerves and just contribute a patch ;)
>>
>> Bye,
>> Norman
>>
>>
>> 2010/4/7 Norman Maurer <norman.maurer@googlemail.com>:
>>> Hi Claus,
>>>
>>> thx for your response :)
>>>
>>> If you look at the documentation of BlobMessage how the message is
>>> send via the producer in activemq:
>>> http://activemq.apache.org/blob-messages.html
>>>
>>> So it would be useful if it would be possible to set the "URL" which
>>> is used by the activemq producer to send the message. The second thing
>>> which would be cool is the possibility to send the body of the camel
>>> message via a BlobMessage. Something like this:
>>>
>>> InputStream in = exchange.getIn().getBody(InputStream.class);
>>> BlobMessage message = session.createBlobMessage(in);
>>> activemqproducer.send(message);
>>>
>>>
>>> The same goes for the consumer. If the cosumed message of activemq is
>>> of the type BlobMessage it should be possible to "cascade" the
>>> getBody() to get the InputStream of the BlobMessage. So the
>>> TypeConverter would do something like this on
>>> getBody(InputStream.class):
>>>
>>> BlobMessage blobMessage = (BlobMessage) message;
>>> InputStream in = blobMessage.getInputStream();
>>> return in;
>>>
>>> Thx,
>>> Norman
>>>
>>>
>>> 2010/4/7 Claus Ibsen <claus.ibsen@gmail.com>:
>>>> Hi
>>>>
>>>> ActiveMQ does not output any javax.jms.StreamMessage, and therfore
>>>> Camel have never needed to map it.
>>>> And I also do not think javax.jms.StreamMessage is used very much?
>>>> Anyone every used them?
>>>>
>>>> In terms of BlobMessage. Can you elaborate a bit? Is there anything in
>>>> the BlobMessage API you needed from Camel?
>>>> Doesn't you get all the data from the blob as a inputstream or the likes?
>>>>
>>>>
>>>>
>>>>
>>>> On Fri, Apr 2, 2010 at 7:48 PM, Norman Maurer <norman@apache.org> wrote:
>>>>> Hi all,
>>>>>
>>>>>  from the Camel in Action book and online docs I see how objects get
>>>>> mapped to the corresponding JMS Message type. I saw that InputStream
>>>>> get mapped to ByteMessage. I wonder why its not using StreamMessage.
>>>>> Anyone knows why ? I thought use StreamMessages would give a real
>>>>> benifit when using big messages.
>>>>> The other thing I would like to see is be able to use BlobMessage when
>>>>> using ActiveMQ component. Is there any plan to support this ?
>>>>>
>>>>>
>>>>> Thx,
>>>>> Norman
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Claus Ibsen
>>>> Apache Camel Committer
>>>>
>>>> Author of Camel in Action: http://www.manning.com/ibsen/
>>>> Open Source Integration: http://fusesource.com
>>>> Blog: http://davsclaus.blogspot.com/
>>>> Twitter: http://twitter.com/davsclaus
>>>>
>>>
>>
>



-- 
Claus Ibsen
Apache Camel Committer

Author of Camel in Action: http://www.manning.com/ibsen/
Open Source Integration: http://fusesource.com
Blog: http://davsclaus.blogspot.com/
Twitter: http://twitter.com/davsclaus

Mime
View raw message