[asterisk-users] limit concurrent calls on trunk supporting multiple DID

Patrick asterisk-users at ict-synergy.be
Fri Sep 18 02:15:22 CDT 2009


This sounds like a clever way to solve my problem.
 But, in the meanwhile, I've already implemented this programatically
from agi script, solving also another requirement I had which was to
limit the number of calls during a certain period (to avoid malicious
sip uri calls flooding the pbx)

Thanks anyway, I'll definately put this useful command on top of my
head. I'm sure I'll need it one day

Patrick



On Fri, Sep 18, 2009 at 02:11, C. Chad Wallace
<cwallace at lodgingcompany.com> wrote:
>
> At 7:16 AM on 17 Sep 2009, Patrick wrote:
>
>> I've one SIP trunk that support multiple DID. Only the trunk is
>> documented in sip.conf (called DID is taken from the sip-header in
>> real time).
>> I would like to limit the number of simultaneous calls on each DID. Is
>> there a way to achieve this ?
>
> I think you could use GROUP() and GROUPCOUNT() for that.  I do that for
> Queue calls currently, so each agent only gets one call at a time.  It
> would go something like this (entirely untested):
>
> [incoming]
> exten => _X.,1,Set(DID=${EXTEN})
> exten => _X.,n,GotoIf($[GROUP_COUNT(${DID})=0]?accept)
> exten => _X.,n,Busy()
>
> exten => _X.,n(accept),Set(GROUP()=${DID})
> ; Now let the call through as usual...
> exten => _X.,n,Goto(mainmenu,s,1)
>
> That puts each call into a group named by the DID, and returns Busy
> if there is another call on the same DID.
>
> --
>
> C. Chad Wallace, B.Sc.
> The Lodging Company
> http://www.skihills.com/
> OpenPGP Public Key ID: 0x262208A0
>
>
> _______________________________________________
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
>
> AstriCon 2009 - October 13 - 15 Phoenix, Arizona
> Register Now: http://www.astricon.net
>
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>   http://lists.digium.com/mailman/listinfo/asterisk-users
>



More information about the asterisk-users mailing list