Module: kamailio Branch: master Commit: 4811a6706e7898049adea7b833caef61b587aff5 URL: https://github.com/kamailio/kamailio/commit/4811a6706e7898049adea7b833caef61...
Author: Daniel-Constantin Mierla miconda@gmail.com Committer: Daniel-Constantin Mierla miconda@gmail.com Date: 2024-12-16T09:10:49+01:00
etc/kamailio.cfg: use dlgs to get dialog stats via rpc
---
Modified: etc/kamailio.cfg
---
Diff: https://github.com/kamailio/kamailio/commit/4811a6706e7898049adea7b833caef61... Patch: https://github.com/kamailio/kamailio/commit/4811a6706e7898049adea7b833caef61...
---
diff --git a/etc/kamailio.cfg b/etc/kamailio.cfg index 606155f02da..ea0aa10ca7e 100644 --- a/etc/kamailio.cfg +++ b/etc/kamailio.cfg @@ -307,6 +307,7 @@ loadmodule "ctl.so" loadmodule "cfg_rpc.so" loadmodule "acc.so" loadmodule "counters.so" +loadmodule "dlgs.so"
#!ifdef WITH_AUTH loadmodule "auth.so" @@ -388,6 +389,12 @@ modparam("rr", "enable_full_lr", 0) # do not append from tag to the RR (no need for this script) modparam("rr", "append_fromtag", 0)
+# ----- dlgs params ----- +modparam("dlgs", "timer_interval", 10) +modparam("dlgs", "init_lifetime", 180) +modparam("dlgs", "active_lifetime", 7200) +modparam("dlgs", "finish_lifetime", 10) + # ----- registrar params ----- modparam("registrar", "method_filtering", 1) /* uncomment the next line to disable parallel forking via location */ @@ -544,6 +551,7 @@ request_route {
# CANCEL processing if (is_method("CANCEL")) { + dlgs_update(); if (t_check_trans()) { route(RELAY); } @@ -596,6 +604,10 @@ request_route { exit; }
+ if(is_method("INVITE")) { + dlgs_init("$fu", "$tu", "srcip=$si"); + } + # dispatch destinations to PSTN route(PSTN);
@@ -681,6 +693,7 @@ route[WITHINDLG] { # take the path determined by record-routing if (loose_route()) { route(DLGURI); + dlgs_update(); if (is_method("BYE")) { setflag(FLT_ACC); # do accounting ... setflag(FLT_ACCFAILED); # ... even if the transaction fails