2
0
Эх сурвалжийг харах

modules: readme files regenerated - mqueue ... [skip ci]

Kamailio Dev 4 жил өмнө
parent
commit
733af50276

+ 57 - 14
src/modules/mqueue/README

@@ -43,6 +43,8 @@ Julien Chavanton
 
 
               3.1. db_url (str)
               3.1. db_url (str)
               3.2. mqueue (string)
               3.2. mqueue (string)
+              3.3. mqueue_name (string)
+              3.4. mqueue_size (int)
 
 
         4. Functions
         4. Functions
 
 
@@ -62,13 +64,15 @@ Julien Chavanton
 
 
    1.1. Set db_url parameter
    1.1. Set db_url parameter
    1.2. Set mqueue parameter
    1.2. Set mqueue parameter
-   1.3. mq_add usage
-   1.4. mq_fetch usage
-   1.5. mq_pv_free usage
-   1.6. mq_size usage
-   1.7. mqueue.get_size usage
-   1.8. mqueue.fetch usage
-   1.9. mqueue.get_sizes usage
+   1.3. Set mqueue_name parameter
+   1.4. Set mqueue_size parameter
+   1.5. mq_add usage
+   1.6. mq_fetch usage
+   1.7. mq_pv_free usage
+   1.8. mq_size usage
+   1.9. mqueue.get_size usage
+   1.10. mqueue.fetch usage
+   1.11. mqueue.get_sizes usage
 
 
 Chapter 1. Admin Guide
 Chapter 1. Admin Guide
 
 
@@ -84,6 +88,8 @@ Chapter 1. Admin Guide
 
 
         3.1. db_url (str)
         3.1. db_url (str)
         3.2. mqueue (string)
         3.2. mqueue (string)
+        3.3. mqueue_name (string)
+        3.4. mqueue_size (int)
 
 
    4. Functions
    4. Functions
 
 
@@ -130,6 +136,8 @@ Chapter 1. Admin Guide
 
 
    3.1. db_url (str)
    3.1. db_url (str)
    3.2. mqueue (string)
    3.2. mqueue (string)
+   3.3. mqueue_name (string)
+   3.4. mqueue_size (int)
 
 
 3.1. db_url (str)
 3.1. db_url (str)
 
 
@@ -180,6 +188,41 @@ modparam("mqueue", "mqueue", "name=myq;size=20;")
 modparam("mqueue", "mqueue", "name=qaz")
 modparam("mqueue", "mqueue", "name=qaz")
 ...
 ...
 
 
+3.3. mqueue_name (string)
+
+   Definition of a memory queue, just by name.
+
+   Default value is “none”.
+
+   Value must be a string.
+
+   The parameter can be set many times, each holding the definition of one
+   queue. The max size of each queue defined this way will be equal to
+   mqueue_size(if mqueue_size configured), or limitless (if mqueue_size
+   not configured).
+
+   Example 1.3. Set mqueue_name parameter
+...
+modparam("mqueue", "mqueue_name", "my_own_queue")
+...
+
+3.4. mqueue_size (int)
+
+   Definition of the size of all memory queues defined via "mqueue_name"
+   parameter.
+
+   Default value is “0”.
+
+   Value must be an int.
+
+   The parameter should be set before defining any "mqueue_name". If not
+   set, the queues defined via "mqueue_name" will be limitless.
+
+   Example 1.4. Set mqueue_size parameter
+...
+modparam("mqueue", "mqueue_size", 1024)
+...
+
 4. Functions
 4. Functions
 
 
    4.1. mq_add(queue, key, value)
    4.1. mq_add(queue, key, value)
@@ -192,7 +235,7 @@ modparam("mqueue", "mqueue", "name=qaz")
    Add a new item (key, value) in the queue. If max size of queue is
    Add a new item (key, value) in the queue. If max size of queue is
    exceeded, the oldest one is removed.
    exceeded, the oldest one is removed.
 
 
-   Example 1.3. mq_add usage
+   Example 1.5. mq_add usage
 ...
 ...
 mq_add("myq", "$rU", "call from $fU");
 mq_add("myq", "$rU", "call from $fU");
 ...
 ...
@@ -205,7 +248,7 @@ mq_add("myq", "$rU", "call from $fU");
    Return: true on success (1); false on failure (-1) or no item fetched
    Return: true on success (1); false on failure (-1) or no item fetched
    (-2).
    (-2).
 
 
-   Example 1.4. mq_fetch usage
+   Example 1.6. mq_fetch usage
 ...
 ...
 while(mq_fetch("myq"))
 while(mq_fetch("myq"))
 {
 {
@@ -218,7 +261,7 @@ while(mq_fetch("myq"))
    Free the item fetched in pseudo-variables. It is optional, a new fetch
    Free the item fetched in pseudo-variables. It is optional, a new fetch
    frees the previous values.
    frees the previous values.
 
 
-   Example 1.5. mq_pv_free usage
+   Example 1.7. mq_pv_free usage
 ...
 ...
 mq_pv_free("myq");
 mq_pv_free("myq");
 ...
 ...
@@ -230,7 +273,7 @@ mq_pv_free("myq");
    If the mqueue is empty, the function returns -1. If the mqueue is not
    If the mqueue is empty, the function returns -1. If the mqueue is not
    found, the function returns -2.
    found, the function returns -2.
 
 
-   Example 1.6. mq_size usage
+   Example 1.8. mq_size usage
 ...
 ...
 $var(q_size) = mq_size("queue");
 $var(q_size) = mq_size("queue");
 xlog("L_INFO", "Size of queue is: $var(q_size)\n");
 xlog("L_INFO", "Size of queue is: $var(q_size)\n");
@@ -260,7 +303,7 @@ xlog("L_INFO", "Size of queue is: $var(q_size)\n");
    Parameters:
    Parameters:
      * name - the name of memory queue
      * name - the name of memory queue
 
 
-   Example 1.7. mqueue.get_size usage
+   Example 1.9. mqueue.get_size usage
 ...
 ...
 kamcmd mqueue.get_size xyz
 kamcmd mqueue.get_size xyz
 ...
 ...
@@ -272,7 +315,7 @@ kamcmd mqueue.get_size xyz
    Parameters:
    Parameters:
      * name - the name of memory queue
      * name - the name of memory queue
 
 
-   Example 1.8. mqueue.fetch usage
+   Example 1.10. mqueue.fetch usage
 ...
 ...
 kamcmd mqueue.fetch xyz
 kamcmd mqueue.fetch xyz
 ...
 ...
@@ -283,7 +326,7 @@ kamcmd mqueue.fetch xyz
 
 
    Parameters: none
    Parameters: none
 
 
-   Example 1.9. mqueue.get_sizes usage
+   Example 1.11. mqueue.get_sizes usage
 ...
 ...
 kamcmd mqueue.get_sizes
 kamcmd mqueue.get_sizes
 ...
 ...

+ 32 - 14
src/modules/rtimer/README

@@ -26,14 +26,16 @@ Daniel-Constantin Mierla
 
 
         3. Parameters
         3. Parameters
 
 
-              3.1. timer (str)
-              3.2. exec (str)
+              3.1. default_interval (int)
+              3.2. timer (str)
+              3.3. exec (str)
 
 
    List of Examples
    List of Examples
 
 
-   1.1. Set timer parameter
-   1.2. Set exec parameter
-   1.3. Use exec parameter with a Kemi engine
+   1.1. Set default_interval parameter
+   1.2. Set timer parameter
+   1.3. Set exec parameter
+   1.4. Use exec parameter with a Kemi engine
 
 
 Chapter 1. Admin Guide
 Chapter 1. Admin Guide
 
 
@@ -47,8 +49,9 @@ Chapter 1. Admin Guide
 
 
    3. Parameters
    3. Parameters
 
 
-        3.1. timer (str)
-        3.2. exec (str)
+        3.1. default_interval (int)
+        3.2. timer (str)
+        3.3. exec (str)
 
 
 1. Overview
 1. Overview
 
 
@@ -76,10 +79,25 @@ Chapter 1. Admin Guide
 
 
 3. Parameters
 3. Parameters
 
 
-   3.1. timer (str)
-   3.2. exec (str)
+   3.1. default_interval (int)
+   3.2. timer (str)
+   3.3. exec (str)
 
 
-3.1. timer (str)
+3.1. default_interval (int)
+
+   The definition of the default interval of timers (if not present on the
+   "timer" parameter)
+
+   The parameter can be set multiple times to get different intervals in
+   same configuration file.
+
+   Example 1.1. Set default_interval parameter
+...
+# default time interval set to 300 seconds
+modparam("rtimer", "default_interval", 300)
+...
+
+3.2. timer (str)
 
 
    The definition of a timer. The value of the parameter must have the
    The definition of a timer. The value of the parameter must have the
    following format:
    following format:
@@ -97,7 +115,7 @@ Chapter 1. Admin Guide
 
 
    Default value is NULL.
    Default value is NULL.
 
 
-   Example 1.1. Set timer parameter
+   Example 1.2. Set timer parameter
 ...
 ...
 # time interval set to 10 seconds
 # time interval set to 10 seconds
 modparam("rtimer", "timer", "name=ta;interval=10;mode=1;")
 modparam("rtimer", "timer", "name=ta;interval=10;mode=1;")
@@ -105,7 +123,7 @@ modparam("rtimer", "timer", "name=ta;interval=10;mode=1;")
 modparam("rtimer", "timer", "name=ta;interval=100000u;mode=1;")
 modparam("rtimer", "timer", "name=ta;interval=100000u;mode=1;")
 ...
 ...
 
 
-3.2. exec (str)
+3.3. exec (str)
 
 
    Specify route to be executed on timer. The value of the parameter must
    Specify route to be executed on timer. The value of the parameter must
    have the following format:
    have the following format:
@@ -120,7 +138,7 @@ modparam("rtimer", "timer", "name=ta;interval=100000u;mode=1;")
 
 
    Default value is NULL.
    Default value is NULL.
 
 
-   Example 1.2. Set exec parameter
+   Example 1.3. Set exec parameter
 ...
 ...
 modparam("rtimer", "timer", "name=ta;interval=10;mode=1;")
 modparam("rtimer", "timer", "name=ta;interval=10;mode=1;")
 modparam("rtimer", "exec", "timer=ta;route=ONTIMER")
 modparam("rtimer", "exec", "timer=ta;route=ONTIMER")
@@ -132,7 +150,7 @@ route[ONTIMER] {
 }
 }
 ...
 ...
 
 
-   Example 1.3. Use exec parameter with a Kemi engine
+   Example 1.4. Use exec parameter with a Kemi engine
 ...
 ...
 modparam("rtimer", "timer", "name=ta;interval=10;mode=1;")
 modparam("rtimer", "timer", "name=ta;interval=10;mode=1;")
 modparam("rtimer", "exec", "timer=ta;route=ksr_rtimer")
 modparam("rtimer", "exec", "timer=ta;route=ksr_rtimer")