activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ttmdev <joe.fernan...@ttmsolutions.com>
Subject Re: How to send file using ActiveMQ
Date Thu, 20 Sep 2007 19:12:16 GMT

I am trying to use the BlobMessage to send a file directly from producer to
consumer. 

All works fine, the BlogMessage message is sent from producer to
consumer;except, the consumer always gets a NULL InputStream when it invokes
BlobMessage.getInputStream();

My BLOB transfer policy is set as follows @ both ends. 

jms.blobTransferPolicy.uploadUrl=http://xx.xx.230.189/uploads

I never see the file on the file server at xx.xx.230.189/uploads. 

What am I missing?

Thanks!


James.Strachan wrote:
> 
> On 6/21/07, Gaurav Hariani <gaurav@blackspark.com> wrote:
>> We have a similar need and after trying a number of approaches we
>> settled on the following approach:
>>
>> The producer creates a file in a directory where it can be served by a
>> webserver e.g. ~gaurav/public_html/large_messages/xyzABC123.zip
>> Then the producer sends the URL of this file as a text message
>> http://server/~gaurav/public_html/large_messages/xyzABC123.zip
>> Consumers read the message and retrieve the file using the contained URL.
>> After a specified interval the producer cleans up the files it has
>> produced (you could change this policy depending on your specific needs)
> 
> BTW the BlobMessage is a nicer option; as it allows you to send files
> directly from the producer; or to pass a remote URL of the file. From
> the consumer side it doesn't know the difference; its just a URL to
> download etc
> -- 
> James
> -------
> http://macstrac.blogspot.com/
> 
> 

-- 
View this message in context: http://www.nabble.com/How-to-send-file-using-ActiveMQ-tf3960326s2354.html#a12803896
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Mime
View raw message