[sr-dev] git:master:604a5c23: http_client Document new "config_file" module param

Olle E. Johansson oej at edvina.net
Wed Feb 3 16:59:21 CET 2016


Module: kamailio
Branch: master
Commit: 604a5c23f0abd15423c8846a5dd4e9403f6b3cd6
URL: https://github.com/kamailio/kamailio/commit/604a5c23f0abd15423c8846a5dd4e9403f6b3cd6

Author: Olle E. Johansson <oej at edvina.net>
Committer: Olle E. Johansson <oej at edvina.net>
Date: 2016-02-03T16:57:06+01:00

http_client Document new "config_file" module param

---

Modified: modules/http_client/doc/http_client_admin.xml

---

Diff:  https://github.com/kamailio/kamailio/commit/604a5c23f0abd15423c8846a5dd4e9403f6b3cd6.diff
Patch: https://github.com/kamailio/kamailio/commit/604a5c23f0abd15423c8846a5dd4e9403f6b3cd6.patch

---

diff --git a/modules/http_client/doc/http_client_admin.xml b/modules/http_client/doc/http_client_admin.xml
index adb22ca..bcb5335 100644
--- a/modules/http_client/doc/http_client_admin.xml
+++ b/modules/http_client/doc/http_client_admin.xml
@@ -28,6 +28,11 @@
 	connection definition.
 	</para>
 	<para>
+	The connections can either be defined with the "httpcon" module parameter
+	or in a separate configuration file, as specified by the "config_file" module
+	parameter. 
+	</para>
+	<para>
 	Like in SIP, the HTTP URL may need encoding to be transported safely
 	over the network. Check the string encoding functions in the Transformation
 	Cookbook (as used in the http_client_query example below).
@@ -357,6 +362,52 @@ modparam("http_client", "httpcon", "apifour=>http://stockholm.example.com/api/ge
 				</programlisting>
 			</example>
 		</section>
+		<section id="http_client.p.config_file">
+			<title><varname>config_file</varname> (string)</title>
+			<para>
+			The file name of a configuration file containing definitions
+			of http connections. This is an alternative to the
+			"httpcon" module parameter - especially when the number of
+			options per line gets too big.
+			</para>
+			<para>
+                	If the file or directory name starts with a '.' the path will be relative to the
+                	working directory (<emphasis>at runtime</emphasis>). If it starts
+                	with a '/' it will be an absolute path and if it starts with anything
+                	else the path will be relative to the main config file directory
+                	(e.g.: for kamailio -f /etc/kamailio/kamailio.cfg it will be relative to /etc/kamailio/).
+        		</para>
+			<para>
+                		The following parameters can be set in the config file, for each connection:
+        		</para>
+        		<itemizedlist>
+                        	<listitem><para>url</para></listitem>
+                        	<listitem><para>username</para></listitem>
+                        	<listitem><para>password</para></listitem>
+                        	<listitem><para>failover</para></listitem>
+                        	<listitem><para>useragent</para></listitem>
+                        	<listitem><para>verify_peer</para></listitem>
+                        	<listitem><para>verify_host</para></listitem>
+                        	<listitem><para>client_cert</para></listitem>
+                        	<listitem><para>client_key</para></listitem>
+                        	<listitem><para>tlsversion</para></listitem>
+                        	<listitem><para>timeout</para></listitem>
+                        	<listitem><para>maxdatasize</para></listitem>
+                        	<listitem><para>http_follow_redirect</para></listitem>
+        		</itemizedlist>
+			See the "httpcon" module parameter for explanation of these settings.
+        		<para>
+                	By default no config file is specified.
+        		</para>
+			<example>
+			<title>Set <varname>config_file</varname> parameter</title>
+				<programlisting format="linespecific">
+...
+modparam("http_client", "config_file", "httpconnections.cfg)
+...
+				</programlisting>
+			</example>
+		</section>
 	</section>
 
 	<section>




More information about the sr-dev mailing list