Browse code

corex: docs - updates to nio related parameters and examples

Daniel-Constantin Mierla authored on 21/05/2020 08:15:14
Showing 1 changed files
... ...
@@ -30,7 +30,7 @@
30 30
 		follow the requirements of the core contributions.
31 31
 	</para>
32 32
 	<para>
33
-		This module now also provides access to network input / output data through
33
+		This module now also provides access to network input / output (nio) data through
34 34
 		event_route[network:msg]. The raw data received from a remote host or about to
35 35
 		be sent to a remote host is available in variable $mb. The script writer may
36 36
 		manipulate this data and save the final result in an AVP defined by msg_avp
... ...
@@ -96,8 +96,8 @@ modparam("corex", "alias_subdomains", "udp:sip-router.org:5060")
96 96
 </programlisting>
97 97
 	    </example>
98 98
 	</section>
99
-    <section id="corex.p.network_io_intercept">
100
-        <title><varname>network_io_intercept</varname> (int)</title>
99
+    <section id="corex.p.nio_intercept">
100
+        <title><varname>nio_intercept</varname> (int)</title>
101 101
         <para>
102 102
             If set to non-zero then raw data received from a remote host or about to
103 103
 			be sent to a remote host is made available in event_route[network:msg].
... ...
@@ -110,19 +110,19 @@ modparam("corex", "alias_subdomains", "udp:sip-router.org:5060")
110 110
         </emphasis>
111 111
         </para>
112 112
         <example>
113
-        <title>Set <varname>network_io_intercept</varname> parameter</title>
113
+        <title>Set <varname>nio_intercept</varname> parameter</title>
114 114
         <programlisting format="linespecific">
115 115
 ...
116
-modparam("corex", "network_io_intercept", 1)
116
+modparam("corex", "nio_intercept", 1)
117 117
 ...
118 118
 </programlisting>
119 119
         </example>
120 120
     </section>
121
-    <section id="corex.p.min_msg_len">
122
-        <title><varname>min_msg_len</varname> (int)</title>
121
+    <section id="corex.p.nio_min_msg_len">
122
+        <title><varname>nio_min_msg_len</varname> (int)</title>
123 123
         <para>
124 124
             Minimum content length of the packet to execute the event_route[network:msg].
125
-			This only works if network_io_intercept parameter is set to non-zero.
125
+			This only works if nio_intercept parameter is set to non-zero.
126 126
         </para>
127 127
         <para>
128 128
         <emphasis>
... ...
@@ -130,20 +130,20 @@ modparam("corex", "network_io_intercept", 1)
130 130
         </emphasis>
131 131
         </para>
132 132
         <example>
133
-        <title>Set <varname>min_msg_len</varname> parameter</title>
133
+        <title>Set <varname>nio_min_msg_len</varname> parameter</title>
134 134
         <programlisting format="linespecific">
135 135
 ...
136
-modparam("corex", "min_msg_len", 32)
136
+modparam("corex", "nio_min_msg_len", 32)
137 137
 ...
138 138
 </programlisting>
139 139
         </example>
140 140
     </section>
141
-    <section id="corex.p.msg_avp">
142
-        <title><varname>msg_avp</varname> (string)</title>
141
+    <section id="corex.p.nio_msg_avp">
142
+        <title><varname>nio_msg_avp</varname> (string)</title>
143 143
         <para>
144 144
             AVP name to store modified content to be set in the packet. If not set in
145 145
             event_route[network:msg], then all changes are lost and original contents
146
-            are used. This only works if network_io_intercept parameter is to set non-zero.
146
+            are used. This only works if nio_intercept parameter is to set non-zero.
147 147
         </para>
148 148
         <para>
149 149
         <emphasis>
... ...
@@ -151,10 +151,10 @@ modparam("corex", "min_msg_len", 32)
151 151
         </emphasis>
152 152
         </para>
153 153
         <example>
154
-        <title>Set <varname>msg_avp</varname> parameter</title>
154
+        <title>Set <varname>nio_msg_avp</varname> parameter</title>
155 155
         <programlisting format="linespecific">
156 156
 ...
157
-modparam("corex", "msg_avp", "$avp(msg)")
157
+modparam("corex", "nio_msg_avp", "$avp(msg)")
158 158
 ...
159 159
 </programlisting>
160 160
         </example>
... ...
@@ -316,7 +316,7 @@ sendx("sip:example.com:5070;transport=sctp", "sctp:2.3.4.5:5060", "Message at $T
316 316
             Returns true if contents of message buffer $mb are the data received from
317 317
             remote host, otherwise false indicating that the contents of $mb are data
318 318
             that is about to be sent out to remote host. This only works if
319
-			network_io_intercept parameter is set to non-zero.
319
+			nio_intercept parameter is set to non-zero.
320 320
         </para>
321 321
         <para>
322 322
         This function can be used from event_route[network:msg].
... ...
@@ -977,7 +977,7 @@ event_route[dispatcher:dst-down] {
977 977
 			by server can be decrypted at client app.
978 978
         </para>
979 979
         <para>
980
-			Next is a basic usage example where encoding and decoding is done using PERL,
980
+			Next is a basic usage example where encoding and decoding is done using PERL.
981 981
         </para>
982 982
         <example>
983 983
         <title><function>event_route[network:msg]</function> use cases</title>
... ...
@@ -991,9 +991,9 @@ modparam("app_perl", "filename", "/usr/local/etc/kamailio/custom_compress.pl")
991 991
 modparam("app_perl", "modpath", "/usr/local/lib64/kamailio/perl")
992 992
 
993 993
 # ----- corex params -----
994
-modparam("corex", "network_io_intercept", 32)
995
-modparam("corex", "min_msg_len", 32)
996
-modparam("corex", "msg_avp", "$avp(msg)")
994
+modparam("corex", "nio_intercept", 32)
995
+modparam("corex", "nio_min_msg_len", 32)
996
+modparam("corex", "nio_msg_avp", "$avp(msg)")
997 997
 ...
998 998
 event_route[network:msg] {
999 999
 	if (is_incoming()) {