[asterisk-dev] CLI development questions

Tzafrir Cohen tzafrir.cohen at xorcom.com
Fri Jul 13 12:55:25 CDT 2007


On Fri, Jul 13, 2007 at 11:52:47PM +0700, Igor A. Goncharovsky wrote:
> Hello, devs!
> 
> I have some ideas of improving CLI of asterisk, before begining write
> code I want to talk about my ideas.
> 
> 1. Improved SIP debug
> First I want to make `sip debug` CLI command more powerful. The new
> functions that can be implemented:
>    a. 1-line debug
>     This will work like 'sip history' command when instead of printing
> all body of message will be printed only address, direction and type of
> message. This can be useful when target is only to have overal info
> about SIP dialogs. This can make much more debug info on one screen.
>    b. debug defined set of SIP dialog type (REGISTER, NOTIFY and etc.)
>      This will allow set dialog types that can be output for host. For
> example when we debug INVITE we can exclude REGISTER and NOTIFY dialogs
> to make debug more readable. 
>    c. debug multiple hosts
>      This will allow setting different debug settings for different
> hosts. I do not know useful it or not.

d. The ability to send sip debug (mayby in the format you suggest in
1.a) to the logs.

> 
> 2. Dump CLI commands
> There are currently command for dump application help, I have seen talks
> about dumping AGI and Manager commands. May be have sense to dump also
> info about CLI commands to tex format?

What actual use do you have for that? Help for specific comamnds (and
applications, and functions, and manager actions) has long been
available. Help is usually just a tab-completion away.

I've implemented a simple "CLI Commands" reference menu with pdmenu for
Xorcom Rapid. It took basically took a very basic shell script.

Frankly I'm not sure if anybody has really used that menu.

> 
> 3. Partial verbose of CLI
> The verbose value set global for all operations. When asterisk have
> several calls it is very hard to understand what is going on. Idea is in
> setting verbose and debug also for single channel, like 'core set
> verbose channel SIP....'

What specific "verbosity domains" do you have in mind?

Channel-specific? Anything more general?

-- 
               Tzafrir Cohen       
icq#16849755                    jabber:tzafrir at jabber.org
+972-50-7952406           mailto:tzafrir.cohen at xorcom.com       
http://www.xorcom.com  iax:guest at local.xorcom.com/tzafrir



More information about the asterisk-dev mailing list