[sr-dev] git:4.1: dispatcher: updated example config to use new db url attributes

Daniel-Constantin Mierla miconda at gmail.com
Tue Jan 21 10:25:14 CET 2014


Module: sip-router
Branch: 4.1
Commit: 3c57dee17e154b8ff4daf72e76134e124a74652b
URL:    http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=3c57dee17e154b8ff4daf72e76134e124a74652b

Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: Daniel-Constantin Mierla <miconda at gmail.com>
Date:   Wed Jan 15 17:00:45 2014 +0100

dispatcher: updated example config to use new db url attributes

(cherry picked from commit a248b53249d76e6b53f72bc64acd4c14fb5db660)

---

 modules/dispatcher/doc/dispatcher.cfg |   11 ++++++-----
 1 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/modules/dispatcher/doc/dispatcher.cfg b/modules/dispatcher/doc/dispatcher.cfg
index b573df5..8c0fc4c 100644
--- a/modules/dispatcher/doc/dispatcher.cfg
+++ b/modules/dispatcher/doc/dispatcher.cfg
@@ -20,6 +20,9 @@
 #     - define WITH_DEBUG
 #
 
+#!ifndef DBURL
+#!define DBURL "mysql://kamailio:kamailiorw@localhost/kamailio"
+#!endif
 
 ####### Global Parameters #########
 
@@ -106,8 +109,7 @@ modparam("tm", "fr_timer", 2000)
 modparam("tm", "fr_inv_timer", 40000)
 
 # ----- dispatcher params -----
-modparam("dispatcher", "db_url",
-	"mysql://openser:openserro@localhost/openser")
+modparam("dispatcher", "db_url", DBURL)
 modparam("dispatcher", "table_name", "dispatcher")
 modparam("dispatcher", "flags", 2)
 modparam("dispatcher", "dst_avp", "$avp(AVP_DST)")
@@ -166,8 +168,6 @@ route {
 
 	# dispatch destinations
 	route(DISPATCH);
-
-	route(RELAY);
 }
 
 
@@ -253,7 +253,8 @@ route[DISPATCH] {
 	}
 	xlog("L_DBG", "--- SCRIPT: going to <$ru> via <$du>\n");
 	t_on_failure("RTF_DISPATCH");
-	return;
+	route(RELAY);
+	exit;
 }
 
 # Sample failure route




More information about the sr-dev mailing list