[rabbitmq-discuss] Parsability of rabbitctrl output

Garrett Smith g at rre.tt
Mon Jun 7 17:57:28 BST 2010


Ah... I should have spotted that one :)

Thanks!

On Mon, Jun 7, 2010 at 11:53 AM, Emile Joubert <emile at rabbitmq.com> wrote:
>
> Hi Garrett,
>
> The output values are separated by a tab character, so you should instruct
> your parser to expect optional values separated by a single tab character.
> The problem you describe only occurs if your pattern consumes an arbitrary
> amount of whitespace.
>
> You may also find the -q flag useful to suppress the first and last line of
> output of the output of rabbitmqctl is being parsed.
>
> (Nice email address btw)
>
> Regards
>
> Emile
>
>
> On 07/06/10 17:14, Garrett Smith wrote:
>>
>> There are some values output by rabbitctrl that are blank/empty, but
>> these are simply omitted from the output. This makes parsing the
>> output difficult. E.g.
>>
>>   rabbitmqctl list_queues name owner_pid memory
>>
>> In cases where owner_pid is blank, the output line has two tokens,
>> three otherwise.
>>
>> Any thoughts on providing a symbol, e.g. "undefined", "-" etc. to help
>> parsers know when a value is empty?
>>
>> Garrett
>> _______________________________________________
>> 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