How to limit the session/connection on DB for each call
Posted: Wed Jun 12, 2019 1:49 pm
Hello Everyone,
We are having issues with DB connection. Is there any other way to limit the connection or session on each call? We are using 8380 as routing extension. Our cluster consists of 20 dialers and each of it has 300 MAX trunks. Technically we are getting almost 8K sessions given the dial method we are using ADAPT_AVERAGE.
Thanks in advance.
[MARIADB]
dsn=asterisk
readsql=select called_count from vicidial_auto_calls a inner join vicidial_list b on a.lead_id=b.lead_id where a.phone_number=${ARG1} limit 1
; AMD detection based from called_count
exten => 8380,1,Playback(sip-silence)
same => n,AGI(agi://127.0.0.1:4577/call_log)
same => n,NoOp(${DIALEDPEERNUMBER:12})
same => n,NoOp(${ODBC_MARIADB(${DIALEDPEERNUMBER:12})})
same => n,GotoIf($[${ODBC_MARIADB(${DIALEDPEERNUMBER:12})}>=4]?AMD:NoAMD)
same => n(AMD),AMD(2000,2000,1000,5000,120,50,4,256)
same => n,NoOp(${AMDSTATUS})
same => n,NoOp(${AMDCAUSE})
same => n,AGI(VD_amd.agi,${EXTEN})
same => n,AGI(agi-VDAD_ALL_outbound.agi,NORMAL-----SO)
same => n,Hangup()
same => n(NoAMD),AGI(agi-VDAD_ALL_outbound.agi,NORMAL-----SO)
same => n,Hangup()
We are having issues with DB connection. Is there any other way to limit the connection or session on each call? We are using 8380 as routing extension. Our cluster consists of 20 dialers and each of it has 300 MAX trunks. Technically we are getting almost 8K sessions given the dial method we are using ADAPT_AVERAGE.
Thanks in advance.
[MARIADB]
dsn=asterisk
readsql=select called_count from vicidial_auto_calls a inner join vicidial_list b on a.lead_id=b.lead_id where a.phone_number=${ARG1} limit 1
; AMD detection based from called_count
exten => 8380,1,Playback(sip-silence)
same => n,AGI(agi://127.0.0.1:4577/call_log)
same => n,NoOp(${DIALEDPEERNUMBER:12})
same => n,NoOp(${ODBC_MARIADB(${DIALEDPEERNUMBER:12})})
same => n,GotoIf($[${ODBC_MARIADB(${DIALEDPEERNUMBER:12})}>=4]?AMD:NoAMD)
same => n(AMD),AMD(2000,2000,1000,5000,120,50,4,256)
same => n,NoOp(${AMDSTATUS})
same => n,NoOp(${AMDCAUSE})
same => n,AGI(VD_amd.agi,${EXTEN})
same => n,AGI(agi-VDAD_ALL_outbound.agi,NORMAL-----SO)
same => n,Hangup()
same => n(NoAMD),AGI(agi-VDAD_ALL_outbound.agi,NORMAL-----SO)
same => n,Hangup()