You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by guillermolalsacien <gu...@sun.com> on 2006/04/10 09:35:00 UTC

How does Reliability work?

I have a few doubts about the acknowledging mechanism:

  - What happens if the acknowledgement message is lost ? Does the provider
send it again ? How reliable is the mechanism or how much can I trust the
provider ?

These questions lead me to ask finally, when should I use the
session.recover() method?
Do I have to detect if a message has been lost myself in order to call
session.recover() ?

Thanks
--
View this message in context: http://www.nabble.com/How-does-Reliability-work--t1423430.html#a3837193
Sent from the ActiveMQ - User forum at Nabble.com.


Re: How does Reliability work?

Posted by Hiram Chirino <hi...@hiramchirino.com>.
On 4/10/06, guillermolalsacien <gu...@sun.com> wrote:
>
> I have a few doubts about the acknowledging mechanism:
>
>   - What happens if the acknowledgement message is lost ? Does the provider
> send it again ? How reliable is the mechanism or how much can I trust the
> provider ?

To loose the ack message, the jms connection would also have to to be
lost.  In this case, the broker re-sends the message to another
consumer.

>
> These questions lead me to ask finally, when should I use the
> session.recover() method?

If you are using client ack, and have received 10 messages without
sending the ack, and something goes wrong with your application (DB
failure or something), and you want to re-process  those 10 messages,
call session.recover()

> Do I have to detect if a message has been lost myself in order to call
> session.recover() ?

To see if the broker is re delivering a message, call
message.getJMSRedelivered()

>
> Thanks
> --
> View this message in context: http://www.nabble.com/How-does-Reliability-work--t1423430.html#a3837193
> Sent from the ActiveMQ - User forum at Nabble.com.
>
>


--
Regards,
Hiram