activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Timothy Bish <tabish...@gmail.com>
Subject Re: Producer Acknowledge in NMS ?
Date Wed, 27 May 2009 13:06:37 GMT
On Wed, 2009-05-27 at 03:20 -0700, mvhoof wrote:
> Hi,
> 
> I have a requirement to built a message queue Consumer/producer which works
> on flaky connections. Now this consumer/producer could be rebooted at all
> times (we have no control over this). So my challenge is this:
> 
> 
> Simply sending the Message using a MessageProducer, i know when a message is
> actually sent, however, this could block the application if the connection
> is down AND, if the machine is rebooted, i could loose the messages .
> 
> Using RequestTimeOut, i could bypass the locking issue, however.. how can i
> find out if a message has been sent or not ? I've read just about everything
> i could find on ActiveMQ and NMS but this does not show up anywhere ? For
> building a trusty system, i really need to know if the message has been sent
> and if not, i can cache it locally until connection is restored.
> 
> Secondly, is there any way to monitor the connection with the broker using
> NMS (we are using the failover protocol) so i can retry sending the chached
> messages as soon as connection is up again ?
> 
> Many thanks in advance !

If you are disabling the blocking sends then there really isn't a way to
check that its been sent.  The blocking send is waiting for
acknowledgment from the broker that it received the message if you use
async sends or use the request timeout option then you give up the
reliability built into the send mechanism.

Regards
Tim.


-- 
Tim Bish
http://fusesource.com
http://timbish.blogspot.com/




Mime
View raw message