diff --git a/src/modules/dialog/README b/src/modules/dialog/README index 533a41caabb..4258d3b3b11 100644 --- a/src/modules/dialog/README +++ b/src/modules/dialog/README @@ -99,19 +99,20 @@ Julien Klingenmeyer 6.47. bridge_contact (string) 6.48. initial_cbs_inscript (int) 6.49. send_bye (int) - 6.50. wait_ack (int) - 6.51. ka_timer (int) - 6.52. ka_interval (int) - 6.53. ka_failed_limit (int) - 6.54. timeout_noreset (int) - 6.55. timer_procs (int) - 6.56. enable_dmq (int) - 6.57. track_cseq_updates (int) - 6.58. lreq_callee_headers (string) - 6.59. event_callback (str) - 6.60. h_id_start (int) - 6.61. h_id_step (int) - 6.62. keep_proxy_rr (string) + 6.50. ignore_non_local_dlg (int) + 6.51. wait_ack (int) + 6.52. ka_timer (int) + 6.53. ka_interval (int) + 6.54. ka_failed_limit (int) + 6.55. timeout_noreset (int) + 6.56. timer_procs (int) + 6.57. enable_dmq (int) + 6.58. track_cseq_updates (int) + 6.59. lreq_callee_headers (string) + 6.60. event_callback (str) + 6.61. h_id_start (int) + 6.62. h_id_step (int) + 6.63. keep_proxy_rr (string) 7. Functions @@ -240,40 +241,41 @@ Julien Klingenmeyer 1.47. Set bridge_contact parameter 1.48. Set initial_cbs_inscript parameter 1.49. Set send_bye parameter - 1.50. Set wait_ack parameter - 1.51. Set ka_timer parameter - 1.52. Set ka_interval parameter - 1.53. Set ka_failed_limit parameter - 1.54. Set timeout_noreset parameter - 1.55. Set timer_procs parameter - 1.56. Set enable_dmq parameter - 1.57. Set track_cseq_updates parameter - 1.58. Set lreq_callee_headers parameter - 1.59. Set event_callback parameter - 1.60. Set h_id_start parameter - 1.61. Set h_id_step parameter - 1.62. Set dlg_keep_proxy_rr parameter - 1.63. set_dlg_profile usage - 1.64. unset_dlg_profile usage - 1.65. is_in_profile usage - 1.66. get_profile_size usage - 1.67. dlg_isflagset usage - 1.68. dlg_setflag usage - 1.69. dlg_resetflag usage - 1.70. dlg_bye usage - 1.71. dlg_refer usage - 1.72. dlg_manage usage - 1.73. dlg_bridge usage - 1.74. dlg_get usage - 1.75. is_known_dlg() usage - 1.76. dlg_set_timeout usage - 1.77. dlg_set_timeout_by_profile usage - 1.78. dlg_set_property usage - 1.79. dlg_remote_profile usage - 1.80. dlg_set_ruri() usage - 1.81. dlg_db_load_callid() usage - 1.82. dlg_db_load_extra() usage - 1.83. dlg_reset_property usage + 1.50. Set ignore_non_local_dlg parameter + 1.51. Set wait_ack parameter + 1.52. Set ka_timer parameter + 1.53. Set ka_interval parameter + 1.54. Set ka_failed_limit parameter + 1.55. Set timeout_noreset parameter + 1.56. Set timer_procs parameter + 1.57. Set enable_dmq parameter + 1.58. Set track_cseq_updates parameter + 1.59. Set lreq_callee_headers parameter + 1.60. Set event_callback parameter + 1.61. Set h_id_start parameter + 1.62. Set h_id_step parameter + 1.63. Set dlg_keep_proxy_rr parameter + 1.64. set_dlg_profile usage + 1.65. unset_dlg_profile usage + 1.66. is_in_profile usage + 1.67. get_profile_size usage + 1.68. dlg_isflagset usage + 1.69. dlg_setflag usage + 1.70. dlg_resetflag usage + 1.71. dlg_bye usage + 1.72. dlg_refer usage + 1.73. dlg_manage usage + 1.74. dlg_bridge usage + 1.75. dlg_get usage + 1.76. is_known_dlg() usage + 1.77. dlg_set_timeout usage + 1.78. dlg_set_timeout_by_profile usage + 1.79. dlg_set_property usage + 1.80. dlg_remote_profile usage + 1.81. dlg_set_ruri() usage + 1.82. dlg_db_load_callid() usage + 1.83. dlg_db_load_extra() usage + 1.84. dlg_reset_property usage Chapter 1. Admin Guide @@ -339,19 +341,20 @@ Chapter 1. Admin Guide 6.47. bridge_contact (string) 6.48. initial_cbs_inscript (int) 6.49. send_bye (int) - 6.50. wait_ack (int) - 6.51. ka_timer (int) - 6.52. ka_interval (int) - 6.53. ka_failed_limit (int) - 6.54. timeout_noreset (int) - 6.55. timer_procs (int) - 6.56. enable_dmq (int) - 6.57. track_cseq_updates (int) - 6.58. lreq_callee_headers (string) - 6.59. event_callback (str) - 6.60. h_id_start (int) - 6.61. h_id_step (int) - 6.62. keep_proxy_rr (string) + 6.50. ignore_non_local_dlg (int) + 6.51. wait_ack (int) + 6.52. ka_timer (int) + 6.53. ka_interval (int) + 6.54. ka_failed_limit (int) + 6.55. timeout_noreset (int) + 6.56. timer_procs (int) + 6.57. enable_dmq (int) + 6.58. track_cseq_updates (int) + 6.59. lreq_callee_headers (string) + 6.60. event_callback (str) + 6.61. h_id_start (int) + 6.62. h_id_step (int) + 6.63. keep_proxy_rr (string) 7. Functions @@ -570,19 +573,20 @@ Chapter 1. Admin Guide 6.47. bridge_contact (string) 6.48. initial_cbs_inscript (int) 6.49. send_bye (int) - 6.50. wait_ack (int) - 6.51. ka_timer (int) - 6.52. ka_interval (int) - 6.53. ka_failed_limit (int) - 6.54. timeout_noreset (int) - 6.55. timer_procs (int) - 6.56. enable_dmq (int) - 6.57. track_cseq_updates (int) - 6.58. lreq_callee_headers (string) - 6.59. event_callback (str) - 6.60. h_id_start (int) - 6.61. h_id_step (int) - 6.62. keep_proxy_rr (string) + 6.50. ignore_non_local_dlg (int) + 6.51. wait_ack (int) + 6.52. ka_timer (int) + 6.53. ka_interval (int) + 6.54. ka_failed_limit (int) + 6.55. timeout_noreset (int) + 6.56. timer_procs (int) + 6.57. enable_dmq (int) + 6.58. track_cseq_updates (int) + 6.59. lreq_callee_headers (string) + 6.60. event_callback (str) + 6.61. h_id_start (int) + 6.62. h_id_step (int) + 6.63. keep_proxy_rr (string) 6.1. enable_stats (integer) @@ -1226,7 +1230,19 @@ modparam("dialog", "initial_cbs_inscript", 0) modparam("dialog", "send_bye", 1) ... -6.50. wait_ack (int) +6.50. ignore_non_local_dlg (int) + + If set to 1, don't send keepalives and do nothing on timeout if dialog + is non local. + + Default value is “0”. + + Example 1.50. Set ignore_non_local_dlg parameter +... +modparam("dialog", "ignore_non_local_dlg", 1) +... + +6.51. wait_ack (int) If set to 1, dialog will be kept a bit longer in memory in order to absorb the ACK negative replies of initial INVITE. If not, the dialog @@ -1235,12 +1251,12 @@ modparam("dialog", "send_bye", 1) Default value is “1”. - Example 1.50. Set wait_ack parameter + Example 1.51. Set wait_ack parameter ... modparam("dialog", "wait_ack", 0) ... -6.51. ka_timer (int) +6.52. ka_timer (int) Keep-alive timer step - how often to execute the callback to send dialog keep alives (SIP OPTIONS requests within dialog). The value @@ -1248,12 +1264,12 @@ modparam("dialog", "wait_ack", 0) Default value is “0” (no keep alive). - Example 1.51. Set ka_timer parameter + Example 1.52. Set ka_timer parameter ... modparam("dialog", "ka_timer", 10) ... -6.52. ka_interval (int) +6.53. ka_interval (int) The interval between keep alives within dialog (SIP OPTIONS requests), sent to caller or callee. The keep alive request will be sent by the @@ -1269,24 +1285,24 @@ modparam("dialog", "ka_timer", 10) Default value is “0” (no keep alive). The lowest settable interval is 30 seconds. - Example 1.52. Set ka_interval parameter + Example 1.53. Set ka_interval parameter ... modparam("dialog", "ka_interval", 300) ... -6.53. ka_failed_limit (int) +6.54. ka_failed_limit (int) The number of failed keep-alive requests that is accepted before generating a dialog timeout. Default value is “1”. - Example 1.53. Set ka_failed_limit parameter + Example 1.54. Set ka_failed_limit parameter ... modparam("dialog", "ka_failed_limit", 5) ... -6.54. timeout_noreset (int) +6.55. timeout_noreset (int) If set to 1, the dialog timeout won't be reset each time a sequential request is processed. It is an alternative to @@ -1294,12 +1310,12 @@ modparam("dialog", "ka_failed_limit", 5) Default value is “0”. - Example 1.54. Set timeout_noreset parameter + Example 1.55. Set timeout_noreset parameter ... modparam("dialog", "timeout_noreset", 1) ... -6.55. timer_procs (int) +6.56. timer_procs (int) If set to 1, the dialog module will start a separate dialog timer process to execute dialog timeout tasks. The default is to use the core @@ -1307,12 +1323,12 @@ modparam("dialog", "timeout_noreset", 1) Default value is “0” (use core timer process). - Example 1.55. Set timer_procs parameter + Example 1.56. Set timer_procs parameter ... modparam("dialog", "timer_procs", 1) ... -6.56. enable_dmq (int) +6.57. enable_dmq (int) If set to 1, the dialog will be synced via dmq. For now, only very basic dialog info is shared, just enough to have synced profiles. @@ -1321,12 +1337,12 @@ modparam("dialog", "timer_procs", 1) Default value is “0”. - Example 1.56. Set enable_dmq parameter + Example 1.57. Set enable_dmq parameter ... modparam("dialog", "enable_dmq", 1) ... -6.57. track_cseq_updates (int) +6.58. track_cseq_updates (int) Enable the callbacks for tracking if CSeq number needs to be updated. It is the case when the INVITE has to be authenticated to downstream @@ -1338,12 +1354,12 @@ modparam("dialog", "enable_dmq", 1) Default value is “0” (disabled). - Example 1.57. Set track_cseq_updates parameter + Example 1.58. Set track_cseq_updates parameter ... modparam("dialog", "track_cseq_updates", 1) ... -6.58. lreq_callee_headers (string) +6.59. lreq_callee_headers (string) SIP headers to be added when sending local generated requests (e.g., BYE) to callee. It can be useful when you use topoh module with call-id @@ -1351,12 +1367,12 @@ modparam("dialog", "track_cseq_updates", 1) Default value is “null”. - Example 1.58. Set lreq_callee_headers parameter + Example 1.59. Set lreq_callee_headers parameter ... modparam("dialog", "lreq_callee_headers", "TH: dlh\r\n") ... -6.59. event_callback (str) +6.60. event_callback (str) The name of the function in the kemi configuration file (embedded scripting language such as Lua, Python, ...) to be executed instead of @@ -1369,7 +1385,7 @@ modparam("dialog", "lreq_callee_headers", "TH: dlh\r\n") Default value is 'empty' (no function is executed for events). - Example 1.59. Set event_callback parameter + Example 1.60. Set event_callback parameter ... modparam("dialog", "event_callback", "ksr_dialog_event") ... @@ -1380,7 +1396,7 @@ function ksr_dialog_event(evname) end ... -6.60. h_id_start (int) +6.61. h_id_start (int) Set the offset to be used for generating dialog internal hash id. If set to -1, the h_id_start is set to the value of the server_id global @@ -1388,12 +1404,12 @@ end Default value is “0”. - Example 1.60. Set h_id_start parameter + Example 1.61. Set h_id_start parameter ... modparam("dialog", "h_id_start", 5) ... -6.61. h_id_step (int) +6.62. h_id_step (int) Set the step to increment the dialog internal hash id. @@ -1410,12 +1426,12 @@ modparam("dialog", "h_id_start", 5) Default value is “1”. - Example 1.61. Set h_id_step parameter + Example 1.62. Set h_id_step parameter ... modparam("dialog", "h_id_step", 10) ... -6.62. keep_proxy_rr (string) +6.63. keep_proxy_rr (string) Whether to keep the record-route header added by the proxy. When enabled, it will keep this proxy's record-route header from the reply. @@ -1430,7 +1446,7 @@ modparam("dialog", "h_id_step", 10) Default value is “0”. - Example 1.62. Set dlg_keep_proxy_rr parameter + Example 1.63. Set dlg_keep_proxy_rr parameter ... modparam("dialog", "keep_proxy_rr", 1) ... @@ -1475,7 +1491,7 @@ modparam("dialog", "keep_proxy_rr", 1) This function can be used from REQUEST_ROUTE, BRANCH_ROUTE, REPLY_ROUTE and FAILURE_ROUTE. - Example 1.63. set_dlg_profile usage + Example 1.64. set_dlg_profile usage ... set_dlg_profile("inbound_call"); set_dlg_profile("caller","$fu"); @@ -1494,7 +1510,7 @@ set_dlg_profile("caller","$fu"); This function can be used from BRANCH_ROUTE, REPLY_ROUTE and FAILURE_ROUTE. - Example 1.64. unset_dlg_profile usage + Example 1.65. unset_dlg_profile usage ... unset_dlg_profile("inbound_call"); unset_dlg_profile("caller","$fu"); @@ -1517,7 +1533,7 @@ unset_dlg_profile("caller","$fu"); This function can be used from REQUEST_ROUTE, BRANCH_ROUTE, REPLY_ROUTE and FAILURE_ROUTE. - Example 1.65. is_in_profile usage + Example 1.66. is_in_profile usage ... if (is_in_profile("inbound_call")) { log("this request belongs to a inbound call\n"); @@ -1547,7 +1563,7 @@ if (is_in_profile("caller","XX")) { This function can be used from REQUEST_ROUTE, BRANCH_ROUTE, REPLY_ROUTE and FAILURE_ROUTE. - Example 1.66. get_profile_size usage + Example 1.67. get_profile_size usage ... if(get_profile_size("inbound_call","$avp(size)")) xlog("currently there are $avp(size) inbound calls\n"); @@ -1566,7 +1582,7 @@ if(get_profile_size("caller","$fu","$avp(size)")) This function can be used from BRANCH_ROUTE, REQUEST_ROUTE, ONREPLY_ROUTE and FAILURE_ROUTE. - Example 1.67. dlg_isflagset usage + Example 1.68. dlg_isflagset usage ... if(dlg_isflagset("1")) { @@ -1584,7 +1600,7 @@ if(dlg_isflagset("1")) This function can be used from BRANCH_ROUTE, REQUEST_ROUTE, ONREPLY_ROUTE and FAILURE_ROUTE. - Example 1.68. dlg_setflag usage + Example 1.69. dlg_setflag usage ... dlg_setflag("1"); ... @@ -1599,7 +1615,7 @@ dlg_setflag("1"); This function can be used from BRANCH_ROUTE, REQUEST_ROUTE, ONREPLY_ROUTE and FAILURE_ROUTE. - Example 1.69. dlg_resetflag usage + Example 1.70. dlg_resetflag usage ... redlg_setflag("1"); ... @@ -1614,7 +1630,7 @@ redlg_setflag("1"); This function can be used from ANY_ROUTE. - Example 1.70. dlg_bye usage + Example 1.71. dlg_bye usage ... dlg_bye("all"); ... @@ -1631,7 +1647,7 @@ dlg_bye("all"); This function can be used from BRANCH_ROUTE, REQUEST_ROUTE, ONREPLY_ROUTE and FAILURE_ROUTE. - Example 1.71. dlg_refer usage + Example 1.72. dlg_refer usage ... dlg_refer("caller", "sip:announcement@kamailio.org"); ... @@ -1644,7 +1660,7 @@ dlg_refer("caller", "sip:announcement@kamailio.org"); This function can be used from REQUEST_ROUTE. - Example 1.72. dlg_manage usage + Example 1.73. dlg_manage usage ... modparam("dialog", "default_timeout", 100) ... @@ -1672,7 +1688,7 @@ request_route { This function can be used from BRANCH_ROUTE, REQUEST_ROUTE, ONREPLY_ROUTE and FAILURE_ROUTE. - Example 1.73. dlg_bridge usage + Example 1.74. dlg_bridge usage ... dlg_bridge("sip:user@kamailio.org", "sip:annoucement@kamailio.org", "sip:kamailio.org:5080"); @@ -1691,7 +1707,7 @@ dlg_bridge("sip:user@kamailio.org", "sip:annoucement@kamailio.org", This function can be used from BRANCH_ROUTE, REQUEST_ROUTE, ONREPLY_ROUTE and FAILURE_ROUTE. - Example 1.74. dlg_get usage + Example 1.75. dlg_get usage ... if(dlg_get("abcdef", "123", "456")) { @@ -1715,7 +1731,7 @@ if(dlg_get("abcdef", "123", "456")) This function can be used from REQUEST_ROUTE, BRANCH_ROUTE, REPLY_ROUTE and FAILURE_ROUTE. - Example 1.75. is_known_dlg() usage + Example 1.76. is_known_dlg() usage ... if(!uri == myself) { if(is_known_dlg()) { @@ -1739,7 +1755,7 @@ if(!uri == myself) { This function can be used from ANY_ROUTE. - Example 1.76. dlg_set_timeout usage + Example 1.77. dlg_set_timeout usage ... if(dlg_set_timeout("180", "123", "456")) { @@ -1761,7 +1777,7 @@ if(dlg_set_timeout("180", "123", "456")) This function can be used from ANY_ROUTE. - Example 1.77. dlg_set_timeout_by_profile usage + Example 1.78. dlg_set_timeout_by_profile usage ... # All dialogs belonging to user abc123 (tracked via set_dlg_profile()) # will be timed out in 3 seconds. @@ -1793,7 +1809,7 @@ dlg_set_timeout_by_profile("users", "abc123", "3"); This function can be used from ANY_ROUTE. - Example 1.78. dlg_set_property usage + Example 1.79. dlg_set_property usage ... dlg_set_property("ka-src"); dlg_set_property("ka-dst"); @@ -1821,7 +1837,7 @@ dlg_set_property("timeout-noreset"); This function can be used from ANY_ROUTE. - Example 1.79. dlg_remote_profile usage + Example 1.80. dlg_remote_profile usage ... $var(exp) = 3600 + $Ts; dlg_remote_profile("add", "caller", "test", "$sruid", "$var(exp)"); @@ -1834,7 +1850,7 @@ dlg_remote_profile("add", "caller", "test", "$sruid", "$var(exp)"); This function can be used from ANY_ROUTE. - Example 1.80. dlg_set_ruri() usage + Example 1.81. dlg_set_ruri() usage ... if(has_totag() and is_present_hf("Route") and uri==myself ) { if(dlg_set_ruri()) { @@ -1850,7 +1866,7 @@ if(has_totag() and is_present_hf("Route") and uri==myself ) { This function can be used from ANY_ROUTE. - Example 1.81. dlg_db_load_callid() usage + Example 1.82. dlg_db_load_callid() usage ... if(has_totag()) { if(!is_known_dlg()) { @@ -1869,7 +1885,7 @@ if(has_totag()) { This function can be used from ANY_ROUTE. - Example 1.82. dlg_db_load_extra() usage + Example 1.83. dlg_db_load_extra() usage ... if(has_totag()) { if(!is_known_dlg()) { @@ -1895,7 +1911,7 @@ if(has_totag()) { This function can be used from ANY_ROUTE. - Example 1.83. dlg_reset_property usage + Example 1.84. dlg_reset_property usage ... dlg_reset_property("ka-src"); dlg_reset_property("ka-dst");