[Asterisk-Dev] Module detect hangup?

Dan Davis DanWDavis at ij.net
Sat Sep 4 06:41:29 MST 2004


You could do cleanup in the "h" extension after the hangup. I currently do
something this this with AGI() and then DEADAGI().

Dan Davis

----- Original Message ----- 
From: "Matthew Boehm" <mboehm at cytelcom.com>
To: <pop at cofradia.org>; "Asterisk Developers Mailing List"
<asterisk-dev at lists.digium.com>
Sent: Saturday, September 04, 2004 12:40 AM
Subject: Re: [Asterisk-Dev] Module detect hangup?


> I've been using COMMIT and ROLLBACK in mysql for quite some time now (at
> least a year).
> MySQL has great transaction support.
>
> But in any case..i do like your suggestion. Makes sense that if they
hangup
> I just rollback the table. But once I COMMIT, I can't rollback. I have to
> commit it right away to prevent others from logging in with that same
> account.
>
> Matthew
>
> ----- Original Message ----- 
> From: "Fernando Romo" <pop at cofradia.org>
> To: "Asterisk Developers Mailing List" <asterisk-dev at lists.digium.com>
> Sent: Friday, September 03, 2004 11:34 PM
> Subject: Re: [Asterisk-Dev] Module detect hangup?
>
>
> > Use PostgreSQL and the transaction log capabilitys with BEGIN
> > Transacction COMMIT and ROLLBACK commands.
> >
> > MySQL is fast DB but don't have the capabilitis of complete or back
> > transactions.... Postgres do.
> >
> > Besta Regards...... Fernando Romo
> >                               pop at cofradia.org
> >
> > Matthew Boehm wrote:
> >
> > >I am writing a module that is writing info to mysql. The problem that I
> am
> > >forseeing is that what happens when a caller calls in, they enter some
> > >digits as their 'login' which updates a 'loggedin' column. The module
> then
> > >gets more info, sound files are played back, the loggedin column is
> updated
> > >to a 'logged out' status and the module hangs up the call.
> > >
> > >What happens if the person hangs up (or call dropped) in the middle of
> this
> > >linear sequence?
> > >
> > >How can the module "catch" or be notified that the person hungup (or
the
> > >call somehow dissappeard) so that I can preform some database cleanup
> (like
> > >logging them out)?
> > >
> > >It seems to me (from what I observe of notice and warning logs) is that
> if a
> > >person hangs up inside a module then the module instance that was
running
> > >just dies.
> > >
> > >Is this true? Is there no way to clean up a dropped call?
> > >
> > >Thanks,
> > >Matthew
> > >
> > >_______________________________________________
> > >Asterisk-Dev mailing list
> > >Asterisk-Dev at lists.digium.com
> > >http://lists.digium.com/mailman/listinfo/asterisk-dev
> > >To UNSUBSCRIBE or update options visit:
> > >   http://lists.digium.com/mailman/listinfo/asterisk-dev
> > >
> > >
> > >
> >
> > _______________________________________________
> > Asterisk-Dev mailing list
> > Asterisk-Dev at lists.digium.com
> > http://lists.digium.com/mailman/listinfo/asterisk-dev
> > To UNSUBSCRIBE or update options visit:
> >    http://lists.digium.com/mailman/listinfo/asterisk-dev
> >
>
> _______________________________________________
> Asterisk-Dev mailing list
> Asterisk-Dev at lists.digium.com
> http://lists.digium.com/mailman/listinfo/asterisk-dev
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-dev





More information about the asterisk-dev mailing list