浏览代码

db_cluster: documented inactive_interval parameter

Daniel-Constantin Mierla 13 年之前
父节点
当前提交
d6fa740aef
共有 2 个文件被更改,包括 48 次插入12 次删除
  1. 26 10
      modules_k/db_cluster/README
  2. 22 2
      modules_k/db_cluster/doc/db_cluster_admin.xml

+ 26 - 10
modules_k/db_cluster/README

@@ -25,8 +25,9 @@ Daniel-Constantin Mierla
 
         3. Parameters
 
-              3.1. connection (int)
-              3.2. cluster (int)
+              3.1. connection (str)
+              3.2. cluster (str)
+              3.3. inactive_interval (int)
 
         4. Usage
 
@@ -34,7 +35,8 @@ Daniel-Constantin Mierla
 
    1.1. Set connection parameter
    1.2. Set cluster parameter
-   1.3. Set cluster parameter
+   1.3. Set inactive_interval parameter
+   1.4. Set cluster parameter
 
 Chapter 1. Admin Guide
 
@@ -48,8 +50,9 @@ Chapter 1. Admin Guide
 
    3. Parameters
 
-        3.1. connection (int)
-        3.2. cluster (int)
+        3.1. connection (str)
+        3.2. cluster (str)
+        3.3. inactive_interval (int)
 
    4. Usage
 
@@ -84,10 +87,11 @@ Chapter 1. Admin Guide
 
 3. Parameters
 
-   3.1. connection (int)
-   3.2. cluster (int)
+   3.1. connection (str)
+   3.2. cluster (str)
+   3.3. inactive_interval (int)
 
-3.1. connection (int)
+3.1. connection (str)
 
    Specify the connection to a real database system. The format is
    'conid=>DBURL' - providing a connection id and the database URL.
@@ -102,7 +106,7 @@ modparam("db_cluster", "connection",
              "con2=>mysql://openser:openser@localhost/kamailio2")
 ...
 
-3.2. cluster (int)
+3.2. cluster (str)
 
    Specify the cluster definition. The format is
    'clsid=>conid1=def1;conid2=def2' - providing a cluster id and the list
@@ -127,6 +131,18 @@ modparam("db_cluster", "connection",
 modparam("db_cluster", "cluster", "cls1=>con1=9s8p;con2=9s8p")
 ...
 
+3.3. inactive_interval (int)
+
+   How long (seconds) a connection is considered inactive after a DB
+   operations failed on it.
+
+   Default value is 300 (5 min).
+
+   Example 1.3. Set inactive_interval parameter
+...
+modparam("db_cluster", "inactive_interval", 180)
+...
+
 4. Usage
 
    Practically, all the modules that want to use a cluster, have to set
@@ -148,7 +164,7 @@ modparam("db_cluster", "cluster", "cls1=>con1=9s8p;con2=9s8p")
    to be used for parallel writing from acc and round-robin reading by
    sqlops.
 
-   Example 1.3. Set cluster parameter
+   Example 1.4. Set cluster parameter
 ...
 modparam("db_cluster", "connection",
              "c1=>mysql://openser:openserrw@localhost/kamailio1")

+ 22 - 2
modules_k/db_cluster/doc/db_cluster_admin.xml

@@ -64,7 +64,7 @@
 	<section>
 	<title>Parameters</title>
 	<section>
-		<title><varname>connection</varname> (int)</title>
+		<title><varname>connection</varname> (str)</title>
 		<para>
 			Specify the connection to a real database system. The format is
 			'conid=>DBURL' - providing a connection id and the database
@@ -88,7 +88,7 @@ modparam("db_cluster", "connection",
 		</example>
 	</section>
 	<section>
-		<title><varname>cluster</varname> (int)</title>
+		<title><varname>cluster</varname> (str)</title>
 		<para>
 			Specify the cluster definition. The format is
 			'clsid=>conid1=def1;conid2=def2' - providing a cluster id and the list of
@@ -118,6 +118,26 @@ modparam("db_cluster", "connection",
 ...
 modparam("db_cluster", "cluster", "cls1=>con1=9s8p;con2=9s8p")
 ...
+</programlisting>
+		</example>
+	</section>
+	<section>
+		<title><varname>inactive_interval</varname> (int)</title>
+		<para>
+			How long (seconds) a connection is considered inactive after a DB
+			operations failed on it.
+		</para>
+		<para>
+		<emphasis>
+			Default value is 300 (5 min).
+		</emphasis>
+		</para>
+		<example>
+		<title>Set <varname>inactive_interval</varname> parameter</title>
+		<programlisting format="linespecific">
+...
+modparam("db_cluster", "inactive_interval", 180)
+...
 </programlisting>
 		</example>
 	</section>