[asterisk-users] Verbose() messages go unnoticed

Philipp Kempgen philipp.kempgen at amooma.de
Sun Jul 26 17:34:35 CDT 2009


Steve Edwards schrieb:
> On Sun, 26 Jul 2009, Philipp Kempgen wrote:
> 
>> Does anybody else have the feeling that custom messages (Verbose(1,...)) 
>> do not stand out enough on the CLI?
> 
> Yes.
> 
>> We're sending messages like "Extension 123 is unknown" to the output and 
>> that should tell the user why a call to 123 fails but users frequently 
>> crank up the verbosity to 3 or 10 so our messages go unnoticed in many 
>> cases.
> 
> Your users can change the verbosity?

Users (== admins) in contrast to developers.

>> My idea was to use terminal escape sequences to make my messages bold 
>> and black on yellow background. apps/app_verbose.c:
> 
> I'm not a big fan of escape sequences and colors because they mung up 
> console log files, greps, text based emails, and not all terminal 
> emulators interpret them correctly even if the TERM environment variable 
> is set correctly.

Of course escape sequences should only be used if Asterisk uses them
for the normal CLI output as well. The -n option or nocolor=yes in the
options section in /etc/asterisk/asterisk.conf should disable them.

> I think "indentation" to indicate significance may be better. Currently 
> (1.2), verbose() indents based on an optional "level" from 0 to 4 as
> follows:
> 
> verbose level 0
>   verbose level 1
>    == verbose level 2
>      -- verbose level 3
>         > verbose level 4
>         > verbose level 5
> 
> with "unspecified" messages displayed as level 0

Same thing in version 1.4.

> If "level 0" was indented one more level than 4, your "level 1" messages 
> would stick out like the proverbial sore thumb from the fire hydrant of a 
> busy console.
> 
> Of course, training admins to stop [ab]using "noop()" would be a great 
> first step :)

Well, the AEL compiler adds lots of calls to NoOp(). These priorities
serve as jump addresses for control structures like if, switch etc.
... NoOp("Console/dsp", "Finish if-if-if-from-pstn-604-606-607") in new stack
IMHO these messages are of very little value to the user (== admin)
unless he/she was debugging the AEL compiler itself. I'd love if the
AEL compiler could downgrade NoOp() to Verbose(6 or higher). But
that's a different story.


    Philipp Kempgen
-- 
AMOOMA GmbH - Bachstr. 126 - 56566 Neuwied  ->  http://www.amooma.de
Geschäftsführer: Stefan Wintermeyer, Handelsregister: Neuwied B14998
Asterisk: http://the-asterisk-book.com - http://das-asterisk-buch.de
Videos of the AMOOCON VoIP conference 2009 ->  http://www.amoocon.de
-- 



More information about the asterisk-users mailing list