On Mon, Feb 23, 2009 at 8:30 AM, Michael Toop <michaelt at bizcall.co.za>wrote: > Hi All, > > I am having a problem with PJSIP (Python application) where PJSIP fails up > with "To many calls". > > Hi Michael, you don't need to call hangup() on DISCONNECTED state since the call is already disconnected. In fact doing that probably will raise an error, or worse cause unexpected result, and that probably explains the try-except protection. The only reason I can think of is if the remote party has been completely gone, so hangup() will take 32 seconds to completely clear the call (that's until BYE retransmission is timeout). Do the remaining calls get stucked forever or will they clear if you wait for 32 seconds or so after calling hangup()? And are you mostly handle incoming calls or outgoing calls? There is also one case where outgoing calls may get stucked forever, remote does not send final response to INVITE when we send CANCEL. cheers Benny I have compiled the library with the following configs, below and it still > fails. I am wondering if I am not hanging up calls properly. I hangup on > DISCONNECT and kill long calls with a function that is called every so > often...code below. > # Kill long calls...called every 10 seconds > log.msg('Total call time now: %s' % c.info().total_time) > if c.info().total_time > int(maxDuration): > log.msg('About to kill the following call over %s s: %s' % \ > (maxDuration, str(c))) > callList.remove(c) > c.hangup(200) > > # in a call callback > if self.call.info().state == pj.CallState.DISCONNECTED: > log.msg('Received client hangup request for call %s'\ > % self.call.info().contact) > try: > self.call.hangup(200) > lib.player_destroy(playerId) > except: > pass > current_call = None > pass > > # define PJSUA_MAX_CALLS 50 > # define PJSUA_MAX_ACC 50 > # define PJSUA_MAX_PLAYERS 50 > # define PJSUA_MAX_RECORDERS 50 > # define PJSUA_MAX_CONF_PORTS (PJSUA_MAX_CALLS+2*PJSUA_MAX_PLAYERS) > # define PJSUA_MAX_BUDDIES 32 > # define PJMEDIA_HAS_INTEL_IPP 1 > > Any thoughts, do I have to delete objects? > > Cheers, > > Michael > > > -- > > Vox Telecom Limited > Block B, Rutherford Estate > > > tel: +27 11 809 1500 > direct: +27 11 809 1646 > mobile: +27 83 364 2370 > fax: 0865 023 695 > - > http://www.voxtelecom.co.za > email:michaelt at voxtelecom.co.za <email%3Amichaelt at voxtelecom.co.za> > > Disclaimer: BizCall does not accept responsibility or liability for the > unauthorised use of its e-mail facility and/or opinions relating to bona > fide company matters. Save for statements and/or opinions relating to bona > fide company matters, Bizcall denies responsibility or liability for the > contents of this communication. > > > > _______________________________________________ > Visit our blog: http://blog.pjsip.org > > pjsip mailing list > pjsip at lists.pjsip.org > http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20090224/a2717b79/attachment.html>