As I require persistence on the messages, I configured the embedded broker to use the MemoryPersistenceAdapter. This allows me to set the persistent flag which I presume will be carried forward into my remote broker which really will persist the message. My network connector using the following URI: static:(failover:(nio://localhost:61616)?trackMessages=true) so I shouldn't lose any messages from the embedded to the remote broker. I do realise that a failure of the process with the embedded broker will lose any in-flight messages that haven't made it to the remote broker, but for my application that risk is acceptable. Let me know if that doesn't do what I expect.
Thanks for the help. Joe On 30 November 2011 16:25, Gary Tully <gary.tu...@gmail.com> wrote: > the typical activemq way to do that is use an embeded vm broker and a > network connector to forward messages to the target when it can. > Disable persistence and it will use a memory store so it will be have > like a buffer. > > On 29 November 2011 16:27, Joe Carter <joe.car...@gmail.com> wrote: >> Hi, >> >> Does anyone know how to configure the connection factory so that it >> will buffer messages while there's a temporary outage to the broker? >> Basically the same as the "Buffered JMS client" in the IBM MQ product >> http://www-10.lotus.com/ldd/lewiki.nsf/dx/01022009113953AMBJANPR.htm >> At the moment my application receives exceptions until the connection >> recovers and I can't afford to block (its a soft real time app). >> If not I'll write my own wrapper but I'd be surprised if there's not >> one out there already. >> >> Thanks >> Joe > > > > -- > http://fusesource.com > http://blog.garytully.com