Hi List,
kazoo module was always using the same timeouts from parameter when making a send/receive call to amqp broker.
there are some use cases where a larger timeout is required but only for that query.
this was corrected by adding a new parameter amqp_query_timeout_avp.
current behavior is preserved.
i would like to backport this commit to 4.2.
does anyone have anything against ?
Best
Below is an example kamailio.conf, where addition of [group] to "db_url" value increases number of mysql connections from 36 to 70. [group] is defined in in my.cfg as:
[group]
ssl-ca=/etc/mysql/ca-cert.pem
ssl-cert=/etc/mysql/client-cert.pem
ssl-key=/etc/mysql/client-key.pem
With sqlops module alone the number of mysql connections is the same with or without [group].
kamailio.conf:
listen=192.98.102.33:5060
fork=yes
log_stderror=no
log_facility=LOG_LOCAL0
debug=2
loadmodule "tm"
loadmodule "auth"
loadmodule "sl"
loadmodule "pv"
loadmodule "auth_db"
loadmodule "dialplan"
loadmodule "domain"
loadmodule "htable"
loadmodule "permissions"
loadmodule "pua"
loadmodule "db_mysql"
loadmodule "sqlops"
loadmodule "xlog"
modparam("auth_db|dialplan|domain|htable|permissions|pua", "db_url", "mysql://user:pass@[group]127.0.0.1/sip_proxy")
modparam("sqlops", "sqlcon", "sip_proxy => mysql://user:pass@[group]127.0.0.1/sip_proxy")
route {
sql_query("sip_proxy", "show status like 'ssl_cipher'", "result");
xlog("L_INFO", "**** got result <variable=$dbr(result=>[0, 0])/value=$dbr(result=>[0, 1])>\n");
sql_result_free("result");
exit;
}
---
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/58
Module: kamailio
Branch: master
Commit: 45c3dbee619f999ddafc79a88d1a49141b76fa9f
URL: https://github.com/kamailio/kamailio/commit/45c3dbee619f999ddafc79a88d1a491…
Author: Olle E. Johansson <oej(a)edvina.net>
Committer: Olle E. Johansson <oej(a)edvina.net>
Date: 2015-02-05T21:18:07+01:00
libkcore Disable checking of /proc files on non-linux systems
---
Modified: lib/kcore/statistics.c
---
Diff: https://github.com/kamailio/kamailio/commit/45c3dbee619f999ddafc79a88d1a491…
Patch: https://github.com/kamailio/kamailio/commit/45c3dbee619f999ddafc79a88d1a491…
---
diff --git a/lib/kcore/statistics.c b/lib/kcore/statistics.c
index 6c63a43..d18b804 100644
--- a/lib/kcore/statistics.c
+++ b/lib/kcore/statistics.c
@@ -371,6 +371,12 @@ static int get_used_waiting_queue(
int waitingQueueSize = 0;
+#ifndef __OS_linux
+ /* /proc/net/tcp and /proc/net/udp only exists on Linux systems, so don't bother with
+ trying to open these files */
+ return 0;
+#endif
+
/* Set up the file we want to open. */
if (forTCP) {
fileToOpen = "/proc/net/tcp";
Module: kamailio
Branch: master
Commit: ea93f1c6da68943fc71de07d9c45c74af697acb3
URL: https://github.com/kamailio/kamailio/commit/ea93f1c6da68943fc71de07d9c45c74…
Author: Olle E. Johansson <oej(a)edvina.net>
Committer: Olle E. Johansson <oej(a)edvina.net>
Date: 2015-02-05T21:11:52+01:00
ratelimit Document dependency on sl
---
Modified: modules/ratelimit/README
Modified: modules/ratelimit/doc/ratelimit_admin.xml
---
Diff: https://github.com/kamailio/kamailio/commit/ea93f1c6da68943fc71de07d9c45c74…
Patch: https://github.com/kamailio/kamailio/commit/ea93f1c6da68943fc71de07d9c45c74…
---
diff --git a/modules/ratelimit/README b/modules/ratelimit/README
index 3051560..fe4ee88 100644
--- a/modules/ratelimit/README
+++ b/modules/ratelimit/README
@@ -245,7 +245,7 @@ Chapter 1. Admin Guide
4.1. Kamailio Modules
The following modules must be loaded before this module:
- * No dependencies on other Kamailio modules.
+ * SL: Stateless request handling.
4.2. External Libraries or Applications
@@ -327,7 +327,7 @@ modparam("ratelimit", "pipe", "4:NETWORK:10000")
6.1. rl_check([pvar])
6.2. rl_check_pipe([pipe_no])
-6.1. rl_check([pvar])
+6.1. rl_check([pvar])
Check the current request against the matched ratelimit algorithm. If
no parameter is provided, the queue will be matched based on method
@@ -374,7 +374,7 @@ modparam("ratelimit", "pipe", "4:NETWORK:10000")
};
...
-6.2. rl_check_pipe([pipe_no])
+6.2. rl_check_pipe([pipe_no])
Check the current request against the matched ratelimit algorithm. If
no parameter is provided, the queue will be matched based on method
@@ -419,7 +419,7 @@ modparam("ratelimit", "pipe", "4:NETWORK:10000")
7.8. rl.push_load
7.9. rl.set_dbg
-7.1. rl.stats
+7.1. rl.stats
Lists the parameters and variables in the ratelimit module.
@@ -430,7 +430,7 @@ modparam("ratelimit", "pipe", "4:NETWORK:10000")
RPC Command Format:
kamcmd rl.stats
-7.2. rl.set_pipe
+7.2. rl.set_pipe
Sets the pipe parameters for the given pipe id.
@@ -444,7 +444,7 @@ modparam("ratelimit", "pipe", "4:NETWORK:10000")
RPC Command Format:
kamcmd rl.set_pipe 2 RED 10
-7.3. rl.get_pipes
+7.3. rl.get_pipes
Gets the list of in use pipes.
@@ -455,7 +455,7 @@ modparam("ratelimit", "pipe", "4:NETWORK:10000")
RPC Command Format:
kamcmd rl.get_pipes
-7.4. rl.set_queue
+7.4. rl.set_queue
Sets the queue parameters for the given queue id.
@@ -469,7 +469,7 @@ modparam("ratelimit", "pipe", "4:NETWORK:10000")
RPC Command Format:
kamcmd rl.set_queue 3 INVITE 2
-7.5. rl.get_queues
+7.5. rl.get_queues
Gets the list of in use queues.
@@ -480,7 +480,7 @@ modparam("ratelimit", "pipe", "4:NETWORK:10000")
RPC Command Format:
kamcmd rl.get_queues
-7.6. rl.set_pid
+7.6. rl.set_pid
Sets the PID Controller parameters for the Feedback Algorithm.
@@ -494,7 +494,7 @@ modparam("ratelimit", "pipe", "4:NETWORK:10000")
RPC Command Format:
kamcmd rl.set_pid 0.5 0.5 0.5
-7.7. rl.get_pid
+7.7. rl.get_pid
Gets the list of in use PID Controller parameters.
@@ -505,7 +505,7 @@ modparam("ratelimit", "pipe", "4:NETWORK:10000")
RPC Command Format:
kamcmd rl.get_pid
-7.8. rl.push_load
+7.8. rl.push_load
Force the value of the load parameter. This method is useful for
testing the Feedback algorithm.
@@ -519,7 +519,7 @@ modparam("ratelimit", "pipe", "4:NETWORK:10000")
RPC Command Format:
kamcmd rl.push_load 0.85
-7.9. rl.set_dbg
+7.9. rl.set_dbg
This function will enable/disable a WARNING debug log exposing the
internal counters for each pipe (useful in monitoring the ratelimit
diff --git a/modules/ratelimit/doc/ratelimit_admin.xml b/modules/ratelimit/doc/ratelimit_admin.xml
index 52843a6..865fc16 100644
--- a/modules/ratelimit/doc/ratelimit_admin.xml
+++ b/modules/ratelimit/doc/ratelimit_admin.xml
@@ -163,7 +163,7 @@
<itemizedlist>
<listitem>
<para>
- <emphasis>No dependencies on other &kamailio; modules</emphasis>.
+ <emphasis>SL: Stateless request handling</emphasis>.
</para>
</listitem>
</itemizedlist>
Pipelimit on non-Linux keeps complaining that it can't read files in /proc/net - repeatedly.
While one warning is a good one, repeating it and filling log files is not a good thing imho.
Tested with git head master
---
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/38
Loading the module in small config with no modparams crash. Updated and installed latest git head after patch to sca for previous crash.
#0 0x000000010a294823 in sca_db_get_connection () at sca_db.c:158
No locals.
#1 0x000000010a2ac1e7 in sca_subscription_db_update () at sca_subscribe.c:493
db_con = (db1_con_t *) 0x0
ht = (sca_hash_table *) 0x69687720726f7272
entry = (sca_hash_entry *) 0x65203a524f525245
sub = (sca_subscription *) 0x7fff8c8362dd
i = 0
rc = -1
now = 1422480694
#2 0x000000010a23f4d9 in sca_mod_destroy () at sca.c:370
No locals.
#3 0x000000010932fe49 in destroy_modules () at sr_module.c:788
t = (struct sr_module *) 0x10977b620
foo = (struct sr_module *) 0x10977b090
#4 0x0000000109185dfb in cleanup (show_status=0) at main.c:512
memlog = 0
#5 0x000000010918d75b in shutdown_children (sig=15, show_status=0) at main.c:654
No locals.
#6 0x00000001091a264d in main (argc=3, argv=0x7fff56b61a98) at main.c:2541
---
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/57
A not documented dependency
'
0(32734) ERROR: pipelimit [./../../modules/sl/sl.h:111]: sl_load_api(): cannot find bind_sl
0(32734) ERROR: pipelimit [pipelimit.c:374]: mod_init(): cannot bind to SL API
0(32734) ERROR: <core> [sr_module.c:945]: init_mod(): Error while initializing module pipelimit (/usr/local/lib64/kamailio/modules/pipelimit.so)
'
Assigned to oej.
---
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/69