[Serdev] [crawford_c@pannaway.com: RE: [Sr] RE: ser development]

Jan Janak jan at iptel.org
Fri Jan 30 20:28:13 UTC 2004


First of all, I agree to what Jiri has written almost completely, I
wanted to post very similar reply.

Comments inline.

On 30-01 20:49, Jan Janak wrote:
> > >2- xml - Rather than loading the ser.cfg through a flat text file,
> load
> > >it through an xml file.
> > 
> > XML benefits are not compellingly obvious to me.
> > 
> > A more interesting possibility to me would be embedding a more
> > general-purpose language with lot of extra functionality, say PHP or
> Perl.
> > 
> 
> Perl/PHP - Interesting, I didn't consider that.  Let me drop back and
> think how that can help our situation.
> 
> XML - Basically, we wanted the user to be able to configure the ser,
> using almost any type of tool that generates XML.  The benefits seen
> here are related to the fact that XML is a standard, and is a marketing
> strategy to say that this particular element can be managed and
> configured via XML.  I can understand if this is not a priority.  As I
> dig into this a little more, I will get more details.  

  I don't see any benefits of converting the configuration file into
  XML. In fact I see drawbacks only. XML may be well suited for
  documents containing structured data, such as docbook, but it is IMHO
  not suitable for imperative languages -- such as ser config file.

  Rewriting it into XML would generate too much overhead. Just imagine a
  C program reformatted into XML.

  One of my basic requirements is that the config file can be read and
  written without any special tools, just using simple text editor.
  Check out how many times users on serusers mailing list send their
  config files and we review them -- that would be hardly possible with XML,
  it would take too much time just to read the file.

  Using specialized XML editors makes no sense here -- you wouldn't be
  able to validate the config file anyway. DTD is too weak and can not
  be used to validate all the constraints -- it would be still possible
  to generate a config file which is perfectly valid according to the
  DTD but which will be refused by ser. XML Schema is bloated, Relax NG
  is still in it's infancy.

  From my experience most of the problems with the config file is
  caused by the fact that ser administrators do not have enough
  knowledge about SIP (even we do not have -- we still learn and fix bugs
  in config files quite often).

  Learning the config file format is easy (trivial if you have C
  background), getting the operational experience and debugging the
  config file is the hard part -- XML will not help here.

  In my opinion extending the existing language or embedding perl are the
  only viable options.

> > >3- Create an Install Anywhere (or something else) application that
> > >prompts users for configurable settings.  The install also
> encapsulates
> > >the other pieces necessary for the features that they wish to support
> > >(e.g. mysql).
> > 
> > That would be very helpful, but not easy. My personal experience is
> that
> > understanding of what a SIP server should do advances week by week and
> > a general-purpose configuration utility is a moving target. We rewrite
> our
> > configuration files every while and we may end up rewriting such a
> tool
> > very frequently as well.
> > 
> 
> Great point.  If we make an Install-Anywhere type of deal, we will keep
> it in house.

  Yes, I agree. The hard part is to compile a proper set of questions
  and it will be evolving and long process.

> Let me clarify.  Here is a simple example. Today we have:
> 
> 		if (lookup("location")) 
>             {
> 			log(1,"===TRACE: src_ip found in usrloc db\n");
> 		}
> 
> We would like something "printf'ish"  
> 
> 		if (lookup("location")) 
>             {
> 			log(1,"===TRACE: %s found in usrloc db\n",
> src_ip);
> 		}
> 

  Check out xlog, it does exactly this.


> We would want a very light MIB for the ser.  Something we can discover
> and read light variables.  Is it in cvs now?  I don't see it in the
> 0.8.12 released source.

  Yes, but in a different CVS module, check out ser_modules instead of
  sip_router.

   Jan. 




More information about the Serdev mailing list