activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Viali.Lee" <Viali....@Hotmail.COM>
Subject Re: Blob Message is a skin game??? not real ?!??
Date Mon, 13 Aug 2007 11:09:49 GMT

I appreciate your reply, and thanks.
but it still doesn't work!
I create a BLOB message using a File / InputStream as the command argument.
BlobMessage message =  session.createBlobMessage(new File("E://test.pdf"));
The sending program seems work fine, but when I tried to get the file data
using a consumer, it gets nothing! (the inputstream I get is null,
therefore, nullpoint exception)
I've tried inputstream way too, but failed again...
I strongly recommend folks try and see what happens about the API...

James.Strachan wrote:
> On 8/13/07, OnlyLove <> wrote:
>> I send the blob message using...
>> BlobMessage message = session.createBlobMessage(new
>> URL("http://localhost:8080/test.pdf"));
>> then, I close the tomcat server, and try to get the message from the amq
>> broker,
>> fail ! (it seems that the blob message just send the url to the broker,
>> but
>> not the real data of the file!)
> This is by design. If you create a blob message using a URL, the
> assumption is that the URL points to some hosted file server / web
> server and that is where the data will remain.
> If you want ActiveMQ to actually take ownership of the data, then
> create a BLOB message using a File / InputStream as the command
> argument. See the JavaDoc.
> also the documentation explains this
> -- 
> James
> -------

View this message in context:
Sent from the ActiveMQ - User mailing list archive at

View raw message