[Freeswitch-users] Problem with originated calls hanging in CS_SOFT_EXEC state

Phillip Boles freeswitch-users at vocalspace.com
Fri Aug 31 20:57:20 MSD 2012


var session =  ManagedSession.OriginateHandleHangup(s, dialString, ts, (y) => {
	try {
		Log.WriteLine(LogLevel.Info, "Hanging UP: "+ y.GetUuid());
		y.SetAutoHangup(true); 
		y.flushDigits();
		y.flushEvents();
		y.destroy();
		y.Dispose();
		GC.Collect();
	}  catch( Exception ) {
		Log.WriteLine(LogLevel.Critical, "Exception While Trying to handup");	
	}
});
Changes yield no fix. Neither .Dispose() or .destroy() separately or together destroy the channel. I see in the log  the hangup 11da29f3-2d9e-4b74-a439-a96ba60f2db1 but  this is what I get from show channels.
The last log lines of the debug is: 
2012-08-31 11:25:52.109393 [DEBUG] switch_core_state_machine.c:407 (sofia/external/XXXXXXXXXX) State Change CS_REPORTING -> CS_DESTROY
2012-08-31 11:25:52.109393 [DEBUG] switch_core_session.c:1224 Send signal sofia/external/XXXXXXXXXX [BREAK]
2012-08-31 11:25:52.109393 [DEBUG] switch_core_session.c:1424 Session 1 (sofia/external/XXXXXXXXXX) Locked, Waiting on external entities


freeswitch at fs03.int.colo> show channels
11da29f3-2d9e-4b74-a439-a96ba60f2db1,outbound,2012-08-31 11:25:24,1346430324,sofia/external/12146635351,CS_SOFT_EXECUTE,Vocalspace,2223334444,,12146635351,,,,default,PCMU,8000,64000,PCMU,8000,64000,,fs03.int.colo,,,ACTIVE,Outbound Call,12146635351,,,,

freeswitch at fs03.int.colo> uuid_kill 11da29f3-2d9e-4b74-a439-a96ba60f2db1

-ERR No Such Channel!

I am calling this from "managed CustomModule.Api"

Calling GC.Collect() later in the execution does not resolve either.
//------------------------------------------------------
// Entrypoint for blocking API execution
//------------------------------------------------------
public void Execute (ApiContext context) {
	
        context.Arguments, context.Event == null ? "<none>" : context.Event.GetEventType ()));

	// this contains the above code
	Run(ParseArguments(context.Arguments));
	GC.Collect();
}

Thanks!
Suggestions appreciated.
On Aug 30, 2012, at 5:22 PM, Dave R. Kompel wrote:

> Actually, all the managed objects are derived from IDisposable, so you should use the .Dispose() method, and let the wrapper do it's job.
> 
> From: Anthony Minessale [mailto:anthony.minessale at gmail.com]
> To: FreeSWITCH Users Help [mailto:freeswitch-users at lists.freeswitch.org]
> Sent: Thu, 30 Aug 2012 13:48:07 -0700
> Subject: Re: [Freeswitch-users] Problem with originated calls hanging in CS_SOFT_EXEC state
> 
> destroy method should have a log line about (destroy/unlink session from object)
> try calling your garbage collector, this is common issue with scripts
> and make sure you are on latest GIT build
> 
> 
> On Thu, Aug 30, 2012 at 3:24 PM, Phillip Boles
> <freeswitch-users at vocalspace.com> wrote:
> > Sorry for the excessive logs. Here is my call to originate.
> >
> > var session = ManagedSession.OriginateHandleHangup(s, dialString, ts, (y)
> > => {
> > try {
> > Log.WriteLine(LogLevel.Info, "Hanging UP: "+ y.GetUuid());
> > y.SetAutoHangup(true);
> > y.destroy();
> >
> > } catch( Exception ) {
> > Log.WriteLine(LogLevel.Critical, "Exception While Trying to handup"); 
> > }
> > });
> >
> >
> > My hangup callback is getting hit and I am destroying the session
> >
> > 2012-08-28 10:49:27.296108 [INFO] switch_cpp.cpp:1227 Handing UP:
> > e315f2e8-1fa8-4fd9-849b-f687dad8aed5
> >
> > This is the only call on the system as it is a develpment machine and I see
> > the call state being changed.
> >
> > 2012-08-28 10:49:27.296108 [DEBUG] switch_core_state_machine.c:79
> > sofia/external/XXXXXXXXXXX Standard REPORTING, cause: NORMAL_CLEARING
> > 2012-08-28 10:49:27.296108 [DEBUG] switch_core_state_machine.c:682
> > (sofia/external/XXXXXXXXXXX) State REPORTING going to sleep
> > 2012-08-28 10:49:27.296108 [DEBUG] switch_core_state_machine.c:407
> > (sofia/external/XXXXXXXXXXX) State Change CS_REPORTING -> CS_DESTROY
> >
> >
> > If I call show channels after the above output it show there is a session
> > sitting in CS_SOFT_EXEC corresponding to UUID
> > e315f2e8-1fa8-4fd9-849b-f687dad8aed5.
> > Is there something else I need to do to release the lock on this session to
> > let the resources be reclaimed.
> >
> > Thanks!
> >
> > Phillip
> >
> >
> >
> >
> > _________________________________________________________________________
> > Professional FreeSWITCH Consulting Services:
> > consulting at freeswitch.org
> > http://www.freeswitchsolutions.com
> >
> > 
> > 
> >
> > Official FreeSWITCH Sites
> > http://www.freeswitch.org
> > http://wiki.freeswitch.org
> > http://www.cluecon.com
> >
> > FreeSWITCH-users mailing list
> > FreeSWITCH-users at lists.freeswitch.org
> > http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> > UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> > http://www.freeswitch.org
> >
> 
> 
> 
> -- 
> Anthony Minessale II
> 
> FreeSWITCH http://www.freeswitch.org/
> ClueCon http://www.cluecon.com/
> Twitter: http://twitter.com/FreeSWITCH_wire
> 
> AIM: anthm
> MSN:anthony_minessale at hotmail.com
> GTALK/JABBER/PAYPAL:anthony.minessale at gmail.com
> IRC: irc.freenode.net #freeswitch
> 
> FreeSWITCH Developer Conference
> sip:888 at conference.freeswitch.org
> googletalk:conf+888 at conference.freeswitch.org
> pstn:+19193869900
> 
> _________________________________________________________________________
> Professional FreeSWITCH Consulting Services:
> consulting at freeswitch.org
> http://www.freeswitchsolutions.com
> 
> 
> 
> 
> Official FreeSWITCH Sites
> http://www.freeswitch.org
> http://wiki.freeswitch.org
> http://www.cluecon.com
> 
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>  
>  
> _________________________________________________________________________
> Professional FreeSWITCH Consulting Services:
> consulting at freeswitch.org
> http://www.freeswitchsolutions.com
> 
> 
> 
> 
> Official FreeSWITCH Sites
> http://www.freeswitch.org
> http://wiki.freeswitch.org
> http://www.cluecon.com
> 
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20120831/0377dae5/attachment.html 


Join us at ClueCon 2011 Aug 9-11, 2011
More information about the FreeSWITCH-users mailing list