[rabbitmq-discuss] active-active implementation in php

Robin Harvey harvey.robin at gmail.com
Sun Jul 22 12:36:21 BST 2012


Hello Frank,

I'll reply on behalf of my Amqp bindings, Amqphp.

Amqphp doesn't support active-active "out of the box", but there is support
for incoming consumer.cancel messages, which AFAIK is one of
the prerequisites for AA.  I'm still unsure how this feature is implemented
in Rabbit, as per my question further up this thread:

Out of interest, how does the client know where to re-connect to when a
> queue fails (i.e. which slave got promoted)?  I've seen the following
> (here: http://www.rabbitmq.com/ha.html):
> > Clients that were consuming from the mirrored-queue and support our
> Consumer Cancellation Notifications extension will receive a notification
> that their subscription to the mirrored-queue has been abruptly cancelled.
> At this point they should re-consume from the queue, which will pick up the
> new master
> ...but this doesn't give much detail.  Are the reconnection parameters in
> the consumer.cancel method?



I must admit that there hasn't been much interest for AA in Amqphp, so I've
left it for now (as I'm working on a new project!).  If people are now
becoming interested in this I would happily look in to what's involved in
setting this up.


Thanks,
--Robin

On 22 July 2012 05:29, thesilentman <od.ravani at gmail.com> wrote:

> Hello Alvaro,
>
> did you find time to test this? I am evaluating rabbitmq for a php project
> and need to know what lib I can use?
>
> Thanks,
> Frank
>
>
> On Tuesday, January 3, 2012 11:00:22 PM UTC+2, Alvaro Videla wrote:
>>
>> Hi Robin,
>>
>> The library implements the basic.cancel method but I haven't tested this
>> yet.
>>
>> I think I will try to set up a Demo and implement any missing features in
>> case they are needed.
>>
>> Alvaro
>>
>> On Jan 3, 2012, at 9:03 PM, Robin Harvey wrote:
>>
>> Alvaro - does php-amqplib support incoming consumer cancels?
>>
>>
>> Out of interest, how does the client know where to re-connect to when a
>> queue fails (i.e. which slave got promoted)?  I've seen the following
>> (here: http://www.rabbitmq.com/ha.**html<http://www.rabbitmq.com/ha.html>
>> ):
>>
>> > Clients that were consuming from the mirrored-queue and support our Consumer
>> Cancellation Notifications<http://www.rabbitmq.com/extensions.html#consumer-cancel-notify>extension will receive a notification that their subscription to the
>> mirrored-queue has been abruptly cancelled. At this point they should
>> re-consume from the queue, which will pick up the new master
>>
>> ...but this doesn't give much detail.  Are the reconnection parameters in
>> the consumer.cancel method?
>>
>>
>> Thanks,
>> --Robin
>>
>> On 3 January 2012 15:07, Alvaro Videla <videlalvaro at gmail.com> wrote:
>>
>>> Hi,
>>>
>>> Yes… it should support the arguments parameter.
>>>
>>> BTW… I recommend that you use this version of the library:
>>> https://github.com/**videlalvaro/php-amqplib<https://github.com/videlalvaro/php-amqplib>for the reasons stated here:
>>> http://videlalvaro.**github.com/2011/11/php-**amqplib-future.html<http://videlalvaro.github.com/2011/11/php-amqplib-future.html>
>>>
>>> Regards,
>>>
>>> Alvaro
>>>
>>>
>>> On Tue, Jan 3, 2012 at 4:00 PM, Emile Joubert <emile at rabbitmq.com>wrote:
>>>
>>>> Hi Dhaneesh,
>>>>
>>>> On 30/12/11 04:25, Dhaneesh Radhakrishnan wrote:
>>>> > Hi
>>>> >
>>>> >  Is it possible to  implement Mirrored Queue ( active-active )using
>>>> > php-ampliqb  for
>>>> > HA
>>>>
>>>> Judging by the queue_declare() function, php-amqplib does support
>>>> arguments, so it is possible to make use of mirrored queues using this
>>>> library.
>>>>
>>>> See http://www.rabbitmq.com/ha.**html <http://www.rabbitmq.com/ha.html>for details on how to set the
>>>> "x-ha-policy" argument.
>>>>
>>>>
>>>>
>>>> -Emile
>>>> ______________________________**_________________
>>>> rabbitmq-discuss mailing list
>>>> rabbitmq-discuss at lists.**rabbitmq.com<rabbitmq-discuss at lists.rabbitmq.com>
>>>> https://lists.rabbitmq.com/**cgi-bin/mailman/listinfo/**
>>>> rabbitmq-discuss<https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss>
>>>>
>>>
>>>
>>> ______________________________**_________________
>>> rabbitmq-discuss mailing list
>>> rabbitmq-discuss at lists.**rabbitmq.com<rabbitmq-discuss at lists.rabbitmq.com>
>>> https://lists.rabbitmq.com/**cgi-bin/mailman/listinfo/**rabbitmq-discuss<https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss>
>>>
>>>
>>
>> Sent form my Nokia 1100
>>
>>
>>
>>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20120722/e5347482/attachment.htm>


More information about the rabbitmq-discuss mailing list