[OpenSIPS-Users] acc with MySQL
Bogdan-Andrei Iancu
bogdan at voice-system.ro
Mon Oct 5 22:19:41 CEST 2009
Hi Brad,
In the ACC table:
http://www.opensips.org/html/docs/db/db-schema-1.5.x.html#AEN31
the value for the "time" column is pushed from opensips (the timestamp
when the request was processed) and not from DB level (via a NOW()
function).
What fields have you seen to be updated via NOW() ?
Regards,
Bogdan
Brad Bendy wrote:
> Hello all,
>
> I noticed this morning that it appears when the acc transaction hits
> MySQL it uses the NOW() function for the date/time fields, BUT that
> function is the true timestamp when it get committed to the database, I
> noticed this when running some alter tables this morning and the table
> was locked and all of sudden we had a long list a 60+ minute calls, all
> the BYE's were at the same timestamp.
>
> In the mean time I have added another field to the acc table with the
> timestamp (that we pull from opensips).
>
> Anyone have any insight on this? I can see why MySQL is doing what's
> it's doing, but for billing purposes like this it's not what I think is
> best, and several race conditions could occur. I would think using
> timestamps in opensips for the SQL statements would be a better choice
> after seeing this, but maybe that is not the case.
>
> Just thinking out loud here and wondering what everyone else thinks as
> well on this subject.
>
> Thanks
>
>
>
>
>
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
>
More information about the Users
mailing list