[Asterisk-Dev] unique cdr id per call

James Golovich james at wwnet.net
Thu Apr 3 14:05:01 MST 2003


I have already done this on some code I am working on.  I believe the
unique id I generated contained the time in seconds, channel number, and
an incrementing number.

This was all bundled into some new functionality I was working on for CDRs
so it would log every event. Unfortunately some of the code has changed so
I need to update my patch and ship it over to mark

James


On Thu, 3 Apr 2003, Michiel Betel wrote:

> After some source reading I think currently CDR's report on call-legs only.
> That will make it pretty hard to report on complex routed calls and to do
> cradle to grave tracing. (CLI is when you get one are not unique) I think it
> would make sense to add a unique ID to a call, e.g. all legs of it (same way
> Aspect & Genesys do).
>  
> Looking at the code this would be do-able in channel.c by adding an ID field
> to the channel struct. If  NULL its the first leg otherwise keep its value
> and write to cdr. If transferred copy it to the new bridge, if hung up the
> channel is gone, thus the ID..
>  
> Still some things to figure out like:
>      how to handle calls from another switch?
>      haven't looked at conferening yet...
>      how to generate a unique number...
>  
> But am I overlooking things?
>  
> Michiel Betel
> 




More information about the asterisk-dev mailing list