Billing
At Vovida Networks, our initial trial customers were service providers who needed to invoice their customers for VoIP services. This section discusses how we implemented an interface to a third-party billing system.
CDR Server
The Call Detail Record (CDR) server is a fairly simple program. Primarily it takes CDRs that represent billing information about a call from the MS and caches them to disk. It can then connect to a billing system using the RADIUS protocol and transfer the records over to the billing system. Because the records are queued on disk, a very large number can be stored, and no billing information is lost if the billing system is down for a day or two.
When the system is configured in a high-reliability configuration, the Marshal dual-writes billing information to a pair of CDR servers. These servers then pass on the data to the billing system whenever it is up. This helps improve performance and reliability. The system can also be configured with just one CDR server , or none if billing is not required.
The bill record
After receiving notifications from the Marshal servers about the start and end of each call, the CDR server generates a bill record that contains a duration field. This field is the calculated difference between the start and end times of the call. These records are cached on the local disk in record file billing.dat. The record file gets rolled over after a configurable size into files with the extension .unsent and with a date and time stamp. ...
Get Practical VoIP Using VOCAL now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.