<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<tt>Hi all,<br>
<br>
This is a heads up regarding some latest changes over OpenSIPS 2.2
/ devel branch, changes that do impact your scripts :<br>
<br>
1) <b>"fork" option replaced wit</b><b>h "debug_mode"</b><br>
The fork/don't fork option made no sense anymore in the new
OpenSIPS architecture (with async reactor). Even more, the so
called "fork" was related only to SIP workers (even with fork=no,
opensips was forking timer process, per-module processes); not to
mention the fork=no limitation to only one UDP interface. Shortly,
the "fork" option became outdated, causing more problem (coding
and experience), rather than something useful.<br>
"debug_mode" option was introduce as better way to switch on and
off a fast way to debug your opensips. </tt><tt>Upon enabling the
"debug_mode", opensips will automatically force:<br>
- staying in foreground (do not detach from console)<br>
- set logging level to 4 (debug)<br>
- set logging to standard error<br>
- enable core dumping<br>
- set UDP worker processes to 2<br>
- set TCP worker processes to 2<br>
<br>
2) <b>"debug" option replaced with "log_level"</b><br>
The global parameter "debug" was renamed "log_level" for a more
accurate description of the setting. The values and the behavior
were kept exactly as before. Of course the MI function "debug" was
renamed to "log_level".<br>
<br>
3) <b>"set_debug()" function replaced with "$log_level" variable</b><br>
Th3e $log_level with behave upon writing exactly as old
set_debug() - a new logging level will be set (as number) or the
log level will be reset (for a NULL input). Even more, the
variable will accept to be populated from other variables/transformations.
Upon reading, the current per process logging level will be
returned. <br>
Ex :<br>
$avp(custom_log_level) = 4;<br>
xlog("Current logging level is $log_level\n");<br>
$log_level = $avp(custom_log_level); /* switch to debug
level */<br>
xlog("Running in debug level (</tt><tt><tt>$log_level)</tt>
now\n");<br>
</tt><tt>$log_level = NULL;<br>
</tt><tt> xlog("Resetting back to logging level
$log_level\n");<br>
<br>
<br>
Any feedback or reports are welcome !<br>
</tt>
<pre class="moz-signature" cols="72">--
Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
<a class="moz-txt-link-freetext" href="http://www.opensips-solutions.com">http://www.opensips-solutions.com</a></pre>
</body>
</html>