-
1. Re: Sending large files over ActiveMQ
dejanb_dejan Dec 9, 2010 10:13 AM (in response to brett_brettl)Hi,
the best way to move large messages is to use Blob messages (http://activemq.apache.org/blob-messages.html). In this scenario the content of the message is transferred through some external server (usually http or ftp) and the rest goes through the broker. This gives the best balance as the large content goes through the infrastructure made to deal with it and doesn't impact the broker.
Hope this helps,
Dejan
Edited by: dejanb on Dec 9, 2010 4:13 PM
-
2. Re: Sending large files over ActiveMQ
rnewcomb_rnewcomb Dec 13, 2010 1:21 PM (in response to brett_brettl)I would favor an out-of-band mechanism for delivering the payload, such as the Blob message described by Dejan, or a simple Text message containing a URL for retrieving the data. Note that the ActiveMQ Blob message is not a standard JMS type, and is therefore non-portable.
If you really want to send the actual payload though the broker network, I recommend using the Stream message instead of programmatically marshalling / chunking the content into separate Bytes messages. The programmatic marshalling mechanism would require a custom unmarshaller on the receiving side - which is undesirable.
The 64KB message chunking size you are observing in the Stream message handling across brokers is likely driven by the TCP transport socket buffer. You may want to tune the TCP configuration for your specific needs .
http://activemq.apache.org/tcp-transport-reference.html
Edited by: rnewcomb on Dec 13, 2010 6:21 PM