Browse code

app_ruby: docs - added note about use of uppercases for KEMI KSR submodules

Daniel-Constantin Mierla authored on 30/05/2018 16:24:45
Showing 1 changed files
... ...
@@ -12,9 +12,9 @@
12 12
 
13 13
 <chapter>
14 14
 
15
-    <title>&adminguide;</title>
15
+	<title>&adminguide;</title>
16 16
 
17
-    <section>
17
+	<section>
18 18
 	<title>Overview</title>
19 19
 	<para>
20 20
 		This module allows executing Ruby scripts from the Kamailio
... ...
@@ -23,8 +23,14 @@
23 23
 		currently processed SIP message. These functions are available within
24 24
 		the Ruby module 'KSR'.
25 25
 	</para>
26
-    </section>
27
-    <section>
26
+	<para>
27
+		IMPORTANT: because of Ruby language policy (which require that a public
28
+		submodule name has to start with an uppercase leter), the KSR submodule
29
+		names are with all leters uppercase. For example, what is documented as
30
+		KSR.sl in KEMI docs, must be used as KSR::SL in Ruby scripts.
31
+	</para>
32
+	</section>
33
+	<section>
28 34
 	<title>Dependencies</title>
29 35
 	<section>
30 36
 	    <title>&kamailio; Modules</title>
... ...
@@ -181,7 +187,7 @@ modparam("app_ruby", "load", "/usr/local/etc/kamailio/ruby/myscript.rb")
181 187
 ...
182 188
 request_route {
183 189
     ...
184
-    if(!jsdt_run("ksr_sl_reply")) {
190
+    if(!ruby_run("ksr_sl_reply")) {
185 191
         xdbg("SCRIPT: failed to execute ruby function!\n");
186 192
     }
187 193
     ...