I am trying to add support for queue.declare arguments in the PHP PECL extension. I have managed to get it to work for x-ha-policy, but x-expires is stumping me. When I try to declare a brand new queue with the x-ha-policy, it works: command returns success and I see the queue in the rabbitmqctl list_queues listing:

!dude002:~/src/pecl/amqp/trunk$ sudo /usr/sbin/rabbitmqctl list_queues name arguments
queue1318463573 [{"x-ha-policy",<<"all">>}]

However, if I replace x-ha-policy with x-expires in the arguments declaration, the queue declaration succeeds (function response is AMQP_RESPONSE_NORMAL) but the queue does not show up in the broker queue listing. The rabbitmq logs show nothing? well, they show that I connected and then disconnected. Nothing else of interest. I don?t know if this is because I am doing something wrong with passing arguments with int values instead of strings (debugging shows the appropriate struct values, but I could be missing something) or because I am doing some other random thing wrong.

How can I debug this behavior? Must I use the Java tools listed here: http://www.rabbitmq.com/examples.html#tracer

Thanks,
Pieter
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20111012/5b681aab/attachment.htm>

Search Discussions

  • Michael Klishin at Oct 13, 2011 at 1:32 am

    Le 13/ott/2011 ? 04:51, Pieter de Zwart a ?crit :

    How can I debug this behavior? Must I use the Java tools listed here: http://www.rabbitmq.com/examples.html#tracer
    I recommend Wireshark (just go with the GUI version and filter by "amqp"). Tracer works great but it has very little documentation and to understand how to use it you need to look into the source. Also, it does not do traffic capturing.

    MK

    http://github.com/michaelklishin
    http://twitter.com/michaelklishin
  • Pieter de Zwart at Oct 13, 2011 at 6:03 am
    Im building this on a remote unix box, so I would first have to get X
    setup before I go all GUI on it. Ill give the command line a shot I guess.
    Thanks for the suggestion!
    me


    On 10/12/11 6:32 PM, "Michael Klishin" wrote:
    Le 13/ott/2011 ? 04:51, Pieter de Zwart a ?crit :

    How can I debug this behavior? Must I use the Java tools listed here:
    http://www.rabbitmq.com/examples.html#tracer
    I recommend Wireshark (just go with the GUI version and filter by
    "amqp"). Tracer works great but it has very little documentation and to
    understand how to use it you need to look into the source. Also, it does
    not do traffic capturing.

    MK

    http://github.com/michaelklishin
    http://twitter.com/michaelklishin
  • Konstantin Sorokin at Oct 13, 2011 at 9:29 pm
    Actually you can use tcpdump to capture and save (look up for the -w
    argument) network stream into the file and then examine it on the machine
    with GUI.
    On Thursday, October 13, 2011 10:03:34 AM UTC+4, Pieter de Zwart wrote:

    Im building this on a remote unix box, so I would first have to get X
    setup before I go all GUI on it. Ill give the command line a shot I guess.
    Thanks for the suggestion!
    -------------- next part --------------
    An HTML attachment was scrubbed...
    URL: <http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20111013/130d0036/attachment.htm>
  • Matthias Radestock at Oct 13, 2011 at 6:23 am
    Pieter,
    On 13/10/11 01:51, Pieter de Zwart wrote:
    However, if I replace x-ha-policy with x-expires in the arguments
    declaration, the queue declaration succeeds (function response is
    AMQP_RESPONSE_NORMAL) but the queue does not show up in the broker queue
    listing.
    Could that be because the queue is, er, expiring?

    Matthias.
  • Simon MacMullen at Oct 13, 2011 at 10:24 am

    On 13/10/11 01:51, Pieter de Zwart wrote:
    The rabbitmq logs show nothing? well, they show that I
    connected and then disconnected. Nothing else of interest.
    Really? Wow. Is your code accessible somewhere and runnable by someone
    who knows nothing about PHP? We should definitely be logging something.

    Cheers, Simon

    --
    Simon MacMullen
    RabbitMQ, VMware
  • Simon MacMullen at Oct 13, 2011 at 10:32 am

    On 13/10/11 11:24, Simon MacMullen wrote:
    On 13/10/11 01:51, Pieter de Zwart wrote:
    The rabbitmq logs show nothing? well, they show that I
    connected and then disconnected. Nothing else of interest.
    Really? Wow. Is your code accessible somewhere and runnable by someone
    who knows nothing about PHP? We should definitely be logging something.
    ...unless, as Matthias points out, the queue is simply expiring before
    you see it and everything is working as designed. Bear in mind that the
    expiry time you provide must be in *milliseconds*.

    Cheers, Simon

    --
    Simon MacMullen
    RabbitMQ, VMware
  • Pieter de Zwart at Oct 13, 2011 at 5:31 pm
    Wow. I thought it was in seconds for some reason. That?s 2hrs of my life I
    wont get back =)

    I guess it all works just fine then.
    Thanks!
    me
    On 10/13/11 3:32 AM, "Simon MacMullen" wrote:
    On 13/10/11 11:24, Simon MacMullen wrote:
    On 13/10/11 01:51, Pieter de Zwart wrote:
    The rabbitmq logs show nothing? well, they show that I
    connected and then disconnected. Nothing else of interest.
    Really? Wow. Is your code accessible somewhere and runnable by someone
    who knows nothing about PHP? We should definitely be logging something.
    ...unless, as Matthias points out, the queue is simply expiring before
    you see it and everything is working as designed. Bear in mind that the
    expiry time you provide must be in *milliseconds*.

    Cheers, Simon

    --
    Simon MacMullen
    RabbitMQ, VMware
    _______________________________________________
    rabbitmq-discuss mailing list
    rabbitmq-discuss at lists.rabbitmq.com
    https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouprabbitmq-discuss @
categoriesrabbitmq
postedOct 13, '11 at 12:51a
activeOct 13, '11 at 9:29p
posts8
users5
websiterabbitmq.com
irc#rabbitmq

People

Translate

site design / logo © 2022 Grokbase