[rabbitmq-discuss] Queue info

Michael Arnoldus chime at mu.dk
Thu Feb 28 09:27:39 GMT 2008


As long as we're just wishing ... :-)

In order of priority:

1. Exposed over AMQP - I send a message to some queue the broker  
listens too and get a reply with the information I need.
2. A very simple command-line tool giving the same info.
3. A nice sexy GUI with bells and whistles :-)

(1) would actually be VERY nice - to the degree that I'd be prepared  
to write something myself when I get some headroom (Rrright! ;-)

Speaking of which - if it should happen that I one late night are  
finding myself sorely missing working in erlang to the degree that I'd  
like to experiment with this - do you have any docs or just pointers  
to how to receive and send AMQP from inside erlang? I guess using the  
erlang AMQP client to let the server talk to itself isn't exactly the  
right approach ...

Michael

On Feb 28, 2008, at 9:25 , Alexis Richardson wrote:

> Thanks Tony.
>
> One other thing that we have been talking about and would love to
> share with others is this: how best to expose these erlang 'management
> functions', such as they are, to users of other languages?
>
> What would people most like to see?  One idea would be to expose
> functions remotely over queues (as reified RPC messages) and then use
> the AMQP, STOMP or HTTP interfaces externally.  Another approach would
> be to use one of the GUI tools, one of the prototype flex clients.
>
> Any thoughts?
>
> alexis
>
>
> On Thu, Feb 28, 2008 at 7:15 AM, Tony Garnock-Jones  
> <tonyg at lshift.net> wrote:
>> Hi Ying,
>>
>>
>> Ying He wrote:
>>> Is there any way in RabbitMQ server for the admin to check for  
>>> example:
>>> How many queues are currently in the system?
>>> How many messages that each one has processed and each one still  
>>> holds
>>> waiting for the consumer to process?
>>
>> There is an undocumented way of doing this. If you start the broker  
>> by
>> running rabbitmq-server, then you end up at an erlang shell (if you
>> don't see the prompt, tap enter to make it reprint it). If you have  
>> the
>> broker running in the background, you need to attach an erlang  
>> shell to
>> it, with a command along the lines of "erl -sname temp -remsh
>> rabbit at yourmachine", running as the same user as the rabbit server.
>>
>> At the erlang prompt, type "rabbit_amqqueue:stat_all().", which will
>> produce a brief report on the status of the queues in the system.  
>> This
>> tells you how many there are, how many consumers are listening on  
>> each,
>> and how many messages are backlogged on each. There is no  
>> indication of
>> how many messages have been through the queues yet. For example:
>>
>> (rabbit at walk)1> rabbit_amqqueue:stat_all().
>> [{ok,{resource,<<"/">>,queue,<<"bar">>},0,1},
>>  {ok,{resource,<<"/">>,queue,<<"foo">>},0,1}]
>>
>> The example shows two queues, "foo" and "bar", each with a single
>> consumer attached (in fact a LogTail.exe instance from our .NET  
>> client),
>> and neither with any messages waiting to be consumed. The result of  
>> the
>> stat_all() call is a list of {status, fully-qualified-queue-name,
>> message-queue-length, consumer-count} tuples.
>>
>> Regards,
>>   Tony
>>
>>
>> _______________________________________________
>> rabbitmq-discuss mailing list
>> rabbitmq-discuss at lists.rabbitmq.com
>> http://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
>>
>
>
>
> -- 
> Alexis Richardson
> +44 20 7617 7339 (UK)
> +44 77 9865 2911 (cell)
> +1 650 206 2517 (US)
>
> _______________________________________________
> rabbitmq-discuss mailing list
> rabbitmq-discuss at lists.rabbitmq.com
> http://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss





More information about the rabbitmq-discuss mailing list