<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
<meta name="Generator" content="MS Exchange Server version
08.03.0083.000">
<title>new functionality: CDR-based accounting</title>
</head>
<body bgcolor="#ffffff" text="#000000">
<!-- Converted from text/plain format -->
<p><font size="2">Hi all,<br>
<br>
as announced quite a while ago, I finally checked in code that
allows to<br>
produce CDRs (Call Data Records) directly from SIP-Router and
generate<br>
logs accordingly.<br>
<br>
The main code portion resides in modules_k/acc and provides a
switch to<br>
enable basic CDR generation including start time, end time, and<br>
duration. Analogous to the existing logging approach, you may
define an<br>
extra parameter covering to-be-included dialog pseudo-variables
that<br>
must be assigned in the configuration script. The new code will
take<br>
care of transforming the basic and custom CDR fields into CDR
logs at<br>
the end of a dialog.<br>
<br>
Speaking of dialogs: The implementation relies heavily on the
dialog<br>
module. It takes advantage of dialog variables introduces by
Carsten<br>
Bock and adds a few more features. Most notably, we had to
change the<br>
dialog callback signature to provide both request and response
messages.<br>
Having only one of them proved to be insufficient in certain
cases; for<br>
instance, a locally generated 408 returned a FAKED_REPLY, thus
rendering<br>
it impossible to access dialog variables through the PV
framework. Other<br>
modules using dialog callbacks have been updated along the
commit,<br>
third-party modules outside the repository will need to do so
too (and<br>
think about whether using the request or response is the Right
Thing to do).<br>
<br>
Due to the changes brought to the dialog module, I pushed the
new acc<br>
and dialog code into a separate branch called treimann/acc-cdr.
Feel<br>
free to give it a try by consulting the updated documentation
and<br>
suggesting (or, if it's good enough, implementing :) )
improvements. A<br>
Kamailio 1.5 backport of the code has been in usage for quite
some time<br>
with us, so generally there shouldn't be any major logical
flaws.<br>
SIP-Router certainly needs more testing, however, so I'd be glad
for any<br>
feedback. My plan is to merge the code into master branch prior
to the<br>
3.2 feature freeze, unless significant objections arise.<br>
<br>
Finally, big-time credits go to my co-worker Sven Knoblich who
is the<br>
main contributor of the code. He's been working on this stuff
for the<br>
past few months and dreams in CDRs by now.<br>
<br>
<br>
Cheers,<br>
<br>
--Timo<br>
</font>
</p>
</body>
</html>