You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by Josh Carlson <jc...@e-dialog.com> on 2010/02/23 19:00:25 UTC

Message State persistence with failover

I've been prototyping a 'shared file system master/slave' 
implementation. I'm using the Stomp protocol in my client and am trying 
to get failover to work properly. Currently when I failover to a new 
master, pending messages are persisted in the new master. However, 
message state seems to be lost. We use client acknowledgements and if I 
have a consumer that retrieves a message from the old master and then 
tries to acknowledge the message on the new master the ack appears to 
succeed but the message stays pending and winds up getting re-delivered.

Is this scenario suppose to work? Any advice would be appreciated.

Thanks

Josh

Re: Message State persistence with failover

Posted by Josh Carlson <jc...@e-dialog.com>.
Actually I still have a problem. If another consumer asks for a message 
before the original consumer acks the message (the ack that spans across 
the broker) the message can be delivered to the other consumer.

On 02/23/2010 01:22 PM, Josh Carlson wrote:
> I answered my own question. In order for this to work my client has to
> re-subscribe to the queues. Doing this solved the issue.
>
> -Josh
>
> On 02/23/2010 01:00 PM, Josh Carlson wrote:
>    
>> I've been prototyping a 'shared file system master/slave'
>> implementation. I'm using the Stomp protocol in my client and am trying
>> to get failover to work properly. Currently when I failover to a new
>> master, pending messages are persisted in the new master. However,
>> message state seems to be lost. We use client acknowledgements and if I
>> have a consumer that retrieves a message from the old master and then
>> tries to acknowledge the message on the new master the ack appears to
>> succeed but the message stays pending and winds up getting re-delivered.
>>
>> Is this scenario suppose to work? Any advice would be appreciated.
>>
>> Thanks
>>
>> Josh
>>
>>      

Re: Message State persistence with failover

Posted by Josh Carlson <jc...@e-dialog.com>.
I answered my own question. In order for this to work my client has to 
re-subscribe to the queues. Doing this solved the issue.

-Josh

On 02/23/2010 01:00 PM, Josh Carlson wrote:
> I've been prototyping a 'shared file system master/slave'
> implementation. I'm using the Stomp protocol in my client and am trying
> to get failover to work properly. Currently when I failover to a new
> master, pending messages are persisted in the new master. However,
> message state seems to be lost. We use client acknowledgements and if I
> have a consumer that retrieves a message from the old master and then
> tries to acknowledge the message on the new master the ack appears to
> succeed but the message stays pending and winds up getting re-delivered.
>
> Is this scenario suppose to work? Any advice would be appreciated.
>
> Thanks
>
> Josh
>