Browse code

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

Kamailio Dev authored on 25/05/2020 09:21:05
Showing 1 changed files
... ...
@@ -10,7 +10,7 @@ Daniel-Constantin Mierla
10 10
 
11 11
    <miconda@gmail.com>
12 12
 
13
-   Copyright � 2010-2019 Daniel-Constantin Mierla (asipto.com)
13
+   Copyright © 2010-2019 Daniel-Constantin Mierla (asipto.com)
14 14
      __________________________________________________________________
15 15
 
16 16
    Table of Contents
... ...
@@ -138,7 +138,7 @@ Chapter 1. Admin Guide
138 138
    Note that 'sr', 'sr.hdr' and 'sr.pv' modules are always registered to
139 139
    Lua.
140 140
 
141
-   Default value is "null".
141
+   Default value is “null”.
142 142
 
143 143
    Example 1.2. Set register parameter
144 144
 ...
Browse code

app_lua_sr: new module split from app_lua to export old Lua sr lib

Daniel-Constantin Mierla authored on 29/05/2019 11:55:26
Showing 1 changed files
1 1
new file mode 100644
... ...
@@ -0,0 +1,146 @@
1
+app_lua_sr Module
2
+
3
+Daniel-Constantin Mierla
4
+
5
+   asipto.com
6
+
7
+Edited by
8
+
9
+Daniel-Constantin Mierla
10
+
11
+   <miconda@gmail.com>
12
+
13
+   Copyright � 2010-2019 Daniel-Constantin Mierla (asipto.com)
14
+     __________________________________________________________________
15
+
16
+   Table of Contents
17
+
18
+   1. Admin Guide
19
+
20
+        1. Overview
21
+        2. Dependencies
22
+
23
+              2.1. Kamailio Modules
24
+              2.2. External Libraries or Applications
25
+
26
+        3. Parameters
27
+
28
+              3.1. register (string)
29
+
30
+   List of Examples
31
+
32
+   1.1. Build against LuaJIT libraries
33
+   1.2. Set register parameter
34
+
35
+Chapter 1. Admin Guide
36
+
37
+   Table of Contents
38
+
39
+   1. Overview
40
+   2. Dependencies
41
+
42
+        2.1. Kamailio Modules
43
+        2.2. External Libraries or Applications
44
+
45
+   3. Parameters
46
+
47
+        3.1. register (string)
48
+
49
+1. Overview
50
+
51
+   This module exports the Lua module 'sr', the old API existing before
52
+   the KEMI framework. The module requires 'app_lua' module.
53
+
54
+   IMPORTANT: this module is kept to allow a smooth migration of the
55
+   scripts using 'sr' module in Lua to KEMI framework and the 'KSR'
56
+   module. It will be marked as obsolete in the near future and removed
57
+   afterwards. If you find any function exported to Lua via 'sr' that has
58
+   no alternative in Lua 'KSR' module, report it to sr-dev mailing list.
59
+
60
+   Lua (http://www.lua.org) is a fast and easy to embed scripting
61
+   language. Exported API from Kamailio to Lua is documented in the
62
+   dokuwiki.
63
+
64
+2. Dependencies
65
+
66
+   2.1. Kamailio Modules
67
+   2.2. External Libraries or Applications
68
+
69
+2.1. Kamailio Modules
70
+
71
+   The following modules must be loaded before this module:
72
+     * app_lua - the Lua interpreter module.
73
+     * various - the modules specified by the 'register' modparam.
74
+
75
+2.2. External Libraries or Applications
76
+
77
+   The following libraries or applications must be installed before
78
+   running Kamailio with this module loaded:
79
+     * liblua5.1-dev - Lua devel library.
80
+
81
+   This module can be compiled against LuaJIT compiler (instead of
82
+   standard Lua). Then this library is needed:
83
+     * libluajit-5.1-dev - LuaJIT devel library.
84
+
85
+   To enable that, LUAJIT variable has to be set.
86
+
87
+   Example 1.1. Build against LuaJIT libraries
88
+   E.g: $ LUAJIT="yes" make modules modules=modules/app_lua_sr
89
+
90
+   (Warning: LuaJIT version is 5.1, so scripts prepared for higher Lua
91
+   versions may not work with LuaJIT)
92
+
93
+3. Parameters
94
+
95
+   3.1. register (string)
96
+
97
+3.1. register (string)
98
+
99
+   NOTE: Since Kamailio v5.0, KEMI exports are available in Lua script
100
+   under KSR module exposed by 'app_lua'. These exports cover most of the
101
+   modules, a lot more that those listed next. The KEMI exports are the
102
+   recommended to be used, the old 'sr' module might be obsoleted soon. To
103
+   read more about KEMI exports and available KSR submodules, see:
104
+     * http://kamailio.org/docs/tutorials/devel/kamailio-kemi-framework/
105
+
106
+   Use this parameter to register optional Kamailio submodules to Lua.
107
+   Available submodules are:
108
+     * alias_db - register functions from alias_db module under
109
+       'sr.alias_db'.
110
+     * auth - register functions from auth module under 'sr.auth'.
111
+     * auth_db - register functions from auth_db module under
112
+       'sr.auth_db'.
113
+     * dispatcher - register functions from dispatcher module under
114
+       'sr.dispatcher'.
115
+     * maxfwd - register functions from maxfwd module under 'sr.maxfwd'.
116
+     * msilo - register functions from msilo module under 'sr.msilo'.
117
+     * presence - register functions from presence module under
118
+       'sr.presence'.
119
+     * presence_xml - register functions from presence_xml module under
120
+       'sr.presence_xml'.
121
+     * pua_usrloc - register functions from pua_usrloc module under
122
+       'sr.pua_usrloc'.
123
+     * registrar - register functions from registrar module under
124
+       'sr.registrar'.
125
+     * rls - register functions from rls module under 'sr.rls'.
126
+     * rr - register functions from rr module under 'sr.rr'.
127
+     * sanity - register functions from sanity module under 'sr.sanity'.
128
+     * sdpops - register functions from sdpops module under 'sr.sdpops'.
129
+     * siputils - register functions from siputils module under
130
+       'sr.siputils'.
131
+     * sl - register functions from sl module under 'sr.sl'.
132
+     * sqlops - register functions from sqlops module under 'sr.sqlops'.
133
+     * textops - register functions from textops module under
134
+       'sr.textops'.
135
+     * tm - register functions from tm module under 'sr.tm'.
136
+     * xhttp - register functions from xhttp module under 'sr.xhttp'.
137
+
138
+   Note that 'sr', 'sr.hdr' and 'sr.pv' modules are always registered to
139
+   Lua.
140
+
141
+   Default value is "null".
142
+
143
+   Example 1.2. Set register parameter
144
+...
145
+modparam("app_lua_sr", "register", "sl")
146
+...