[sr-dev] git:master:7ff8f040: dialog: documented dlg_db_load_extra() function

Daniel-Constantin Mierla miconda at gmail.com
Fri Apr 6 09:23:41 CEST 2018


Module: kamailio
Branch: master
Commit: 7ff8f04079fc9c7e6710b43c3e893518f17ef48e
URL: https://github.com/kamailio/kamailio/commit/7ff8f04079fc9c7e6710b43c3e893518f17ef48e

Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: Daniel-Constantin Mierla <miconda at gmail.com>
Date: 2018-04-06T09:21:56+02:00

dialog: documented dlg_db_load_extra() function

- related to #1274

---

Modified: src/modules/dialog/doc/dialog_admin.xml

---

Diff:  https://github.com/kamailio/kamailio/commit/7ff8f04079fc9c7e6710b43c3e893518f17ef48e.diff
Patch: https://github.com/kamailio/kamailio/commit/7ff8f04079fc9c7e6710b43c3e893518f17ef48e.patch

---

diff --git a/src/modules/dialog/doc/dialog_admin.xml b/src/modules/dialog/doc/dialog_admin.xml
index d231d9a2f6..5ed51d450d 100644
--- a/src/modules/dialog/doc/dialog_admin.xml
+++ b/src/modules/dialog/doc/dialog_admin.xml
@@ -1552,12 +1552,12 @@ modparam("dialog", "h_id_start", 5)
 			with the rule: h_id_start + N * h_id_step. The first value of N is
 			randomly selected at startup, then incremented by 1 for each new
 			dialog. Setting h_id_start and h_id_step to non-default values
-			should be done when using dlg_db_load_callid(...) to load dialog
-			records generated by another &kamailio; instance, making also sure
-			that those &kamailio; instances are not going to generate
-			overalapping dialog hash id values by using different h_id_start
-			and the same h_id_step (h_id_step has to be greater than the
-			maximum value of h_id_start).
+			should be done when using dlg_db_load_callid(...) or
+			dlg_db_load_extra() to load dialog records generated by another
+			&kamailio; instance, making also sure that those &kamailio; 
+			nstances are not going to generate overalapping dialog hash id
+			values by using different h_id_start and the same h_id_step
+			(h_id_step has to be greater than the maximum value of h_id_start).
 		</para>
 		<para>
 		<emphasis>
@@ -2281,6 +2281,33 @@ if(has_totag()) {
     }
 }
 ...
+</programlisting>
+		</example>
+	</section>
+	<section id="dialog.f.dlg_db_load_extra">
+		<title>
+		<function moreinfo="none">dlg_db_load_extra()</function>
+		</title>
+		<para>
+		Load all dialog records from database that are not in memory of the
+		current &kamailio; instance.
+		</para>
+		<para>
+		This function can be used from ANY_ROUTE.
+		</para>
+		<example>
+		<title><function>dlg_db_load_extra()</function> usage</title>
+		<programlisting format="linespecific">
+...
+if(has_totag()) {
+    if(!is_known_dlg()) {
+        dlg_db_load_extra();
+	    if(!is_known_dlg()) {
+            xlog("no dialog found with callid: $ci\n");
+        }
+    }
+}
+...
 </programlisting>
 		</example>
 	</section>




More information about the sr-dev mailing list