Hello list.<div><br></div><div>I am developing a module that keeps track of all calls passing through the server. The goal is to maintain a state in order to be able to hang up the calls that run out of credit when the time comes. The module makes use of the tm public interface and shared memory mechanism to maintain all the relevant data in shared memory and precisely this was the motivation for building this module from scratch instead of writing a client for the dialog module with an external app doing the credit control logic and a MySQL database in the backend.</div>
<div><br></div><div>Basically, this is how it works:</div><div><br></div><div>- In the config script it receives a unique identifier of the client along with the credit available for it and the discount that should be made every second.</div>
<div>- A loop iterates over the current calls and when the credit is exhausted, a BYE message is sent to both legs. </div><div>- Everything is kept in shared memory, no need to having an external database nor dialog module.</div>
<div>- It is transaction-oriented.</div><div><br></div><div>The project needs to implement some business-specific (private) logic and before that to happen I would like to know if the raw version of the module, with its features, could be useful to the community?, or I just reinvented the wheel?</div>
<div><br></div><div>Regards.</div><div><br></div><div>Carlos.</div>