Browse code

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

Kamailio Dev authored on 07/09/2021 11:16:24
Showing 1 changed files
... ...
@@ -33,9 +33,10 @@ Elena-Ramona Modroiu
33 33
               4.2. force_color (integer)
34 34
               4.3. long_format (integer)
35 35
               4.4. prefix (str)
36
-              4.5. log_facility (string)
37
-              4.6. log_colors (string)
38
-              4.7. methods_filter (int)
36
+              4.5. prefix_mode (str)
37
+              4.6. log_facility (string)
38
+              4.7. log_colors (string)
39
+              4.8. methods_filter (int)
39 40
 
40 41
         5. Functions
41 42
 
... ...
@@ -58,18 +59,19 @@ Elena-Ramona Modroiu
58 59
    1.2. Set force_color parameter
59 60
    1.3. Set long_format parameter
60 61
    1.4. Set prefix parameter
61
-   1.5. log_facility example
62
-   1.6. log_colors example
63
-   1.7. Set methods_filter parameter
64
-   1.8. xlog usage
65
-   1.9. xdbg usage
66
-   1.10. xinfo usage
67
-   1.11. xnotice usage
68
-   1.12. xwarn usage
69
-   1.13. xerr usage
70
-   1.14. xbug usage
71
-   1.15. xcrit usage
72
-   1.16. xalert usage
62
+   1.5. Set prefix_mode parameter
63
+   1.6. log_facility example
64
+   1.7. log_colors example
65
+   1.8. Set methods_filter parameter
66
+   1.9. xlog usage
67
+   1.10. xdbg usage
68
+   1.11. xinfo usage
69
+   1.12. xnotice usage
70
+   1.13. xwarn usage
71
+   1.14. xerr usage
72
+   1.15. xbug usage
73
+   1.16. xcrit usage
74
+   1.17. xalert usage
73 75
 
74 76
 Chapter 1. Admin Guide
75 77
 
... ...
@@ -88,9 +90,10 @@ Chapter 1. Admin Guide
88 90
         4.2. force_color (integer)
89 91
         4.3. long_format (integer)
90 92
         4.4. prefix (str)
91
-        4.5. log_facility (string)
92
-        4.6. log_colors (string)
93
-        4.7. methods_filter (int)
93
+        4.5. prefix_mode (str)
94
+        4.6. log_facility (string)
95
+        4.7. log_colors (string)
96
+        4.8. methods_filter (int)
94 97
 
95 98
    5. Functions
96 99
 
... ...
@@ -155,9 +158,10 @@ Chapter 1. Admin Guide
155 158
    4.2. force_color (integer)
156 159
    4.3. long_format (integer)
157 160
    4.4. prefix (str)
158
-   4.5. log_facility (string)
159
-   4.6. log_colors (string)
160
-   4.7. methods_filter (int)
161
+   4.5. prefix_mode (str)
162
+   4.6. log_facility (string)
163
+   4.7. log_colors (string)
164
+   4.8. methods_filter (int)
161 165
 
162 166
 4.1. buf_size (integer)
163 167
 
... ...
@@ -205,7 +209,21 @@ modparam("xlog", "long_format", 1)
205 209
 modparam("xlog", "prefix", "-xlog: ")
206 210
 ...
207 211
 
208
-4.5. log_facility (string)
212
+4.5. prefix_mode (str)
213
+
214
+   control behaviour of prefix value. if mode = 0 then prefix is treated
215
+   as string (current behaviour). if mode = 1 then prefix is treated as
216
+   pv_format specifier and value will be evaluated before output.
217
+
218
+   Default value is 0.
219
+
220
+   Example 1.5. Set prefix_mode parameter
221
+...
222
+modparam("xlog", "prefix", "$cfg(name):$cfg(line)")
223
+modparam("xlog", "prefix_mode", 1)
224
+...
225
+
226
+4.6. log_facility (string)
209 227
 
210 228
    Syslog facility to be used for the xlog output. By setting this, and
211 229
    configuring syslog, you can get the xlog messages in a separate syslog
... ...
@@ -214,10 +232,10 @@ modparam("xlog", "prefix", "-xlog: ")
214 232
    Default value is NULL (unset - use same facility as source code debug
215 233
    messages).
216 234
 
217
-   Example 1.5. log_facility example
235
+   Example 1.6. log_facility example
218 236
 modparam("xlog", "log_facility", "LOG_DAEMON")
219 237
 
220
-4.6. log_colors (string)
238
+4.7. log_colors (string)
221 239
 
222 240
    Update terminal colors used by the Kamailio core for log levels (when
223 241
    log_stderr=1 and log_color=1). The value has to be 'logname=colors',
... ...
@@ -229,11 +247,11 @@ modparam("xlog", "log_facility", "LOG_DAEMON")
229 247
 
230 248
    Default value is NULL.
231 249
 
232
-   Example 1.6. log_colors example
250
+   Example 1.7. log_colors example
233 251
 modparam("xlog", "log_colors", "L_ERR=cr")
234 252
 modparam("xlog", "log_colors", "L_ERR=cr;L_WARN=px")
235 253
 
236
-4.7. methods_filter (int)
254
+4.8. methods_filter (int)
237 255
 
238 256
    The bitmask with internal SIP method ids to be ignored by xlogm()
239 257
    function. The value can be changed at runtime via cfg reload framework:
... ...
@@ -246,7 +264,7 @@ kamcmd cfg.set_now_int xlog methods_filter 15
246 264
 
247 265
    Default value is -1 (all SIP methods are ignored).
248 266
 
249
-   Example 1.7. Set methods_filter parameter
267
+   Example 1.8. Set methods_filter parameter
250 268
 ...
251 269
 modparam("xlog", "long_format", 1)
252 270
 ...
... ...
@@ -295,7 +313,7 @@ modparam("xlog", "long_format", 1)
295 313
 
296 314
    This function can be used from ANY_ROUTE.
297 315
 
298
-   Example 1.8. xlog usage
316
+   Example 1.9. xlog usage
299 317
 ...
300 318
 xlog("L_ERR", "time [$Tf] method ($rm) r-uri ($ru) 2nd via ($hdr(via[1]))\n");
301 319
 ...
... ...
@@ -317,7 +335,7 @@ CAL3\n");
317 335
 
318 336
    This function can be used from ANY_ROUTE.
319 337
 
320
-   Example 1.9. xdbg usage
338
+   Example 1.10. xdbg usage
321 339
 ...
322 340
 xdbg("time $Cbx[$Tf]$Cxx method ($rm) r-uri ($ru)\n");
323 341
 ...
... ...
@@ -331,7 +349,7 @@ xdbg("time $Cbx[$Tf]$Cxx method ($rm) r-uri ($ru)\n");
331 349
 
332 350
    This function can be used from ANY_ROUTE.
333 351
 
334
-   Example 1.10. xinfo usage
352
+   Example 1.11. xinfo usage
335 353
 ...
336 354
 xinfo("time $Cbx[$Tf]$Cxx method ($rm) r-uri ($ru)\n");
337 355
 ...
... ...
@@ -345,7 +363,7 @@ xinfo("time $Cbx[$Tf]$Cxx method ($rm) r-uri ($ru)\n");
345 363
 
346 364
    This function can be used from ANY_ROUTE.
347 365
 
348
-   Example 1.11. xnotice usage
366
+   Example 1.12. xnotice usage
349 367
 ...
350 368
 xnotice("time $Cbx[$Tf]$Cxx method ($rm) r-uri ($ru)\n");
351 369
 ...
... ...
@@ -359,7 +377,7 @@ xnotice("time $Cbx[$Tf]$Cxx method ($rm) r-uri ($ru)\n");
359 377
 
360 378
    This function can be used from ANY_ROUTE.
361 379
 
362
-   Example 1.12. xwarn usage
380
+   Example 1.13. xwarn usage
363 381
 ...
364 382
 xwarn("time $Cbx[$Tf]$Cxx method ($rm) r-uri ($ru)\n");
365 383
 ...
... ...
@@ -373,7 +391,7 @@ xwarn("time $Cbx[$Tf]$Cxx method ($rm) r-uri ($ru)\n");
373 391
 
374 392
    This function can be used from ANY_ROUTE.
375 393
 
376
-   Example 1.13. xerr usage
394
+   Example 1.14. xerr usage
377 395
 ...
378 396
 xerr("time $Cbx[$Tf]$Cxx method ($rm) r-uri ($ru)\n");
379 397
 ...
... ...
@@ -387,7 +405,7 @@ xerr("time $Cbx[$Tf]$Cxx method ($rm) r-uri ($ru)\n");
387 405
 
388 406
    This function can be used from ANY_ROUTE.
389 407
 
390
-   Example 1.14. xbug usage
408
+   Example 1.15. xbug usage
391 409
 ...
392 410
 xbug("time $Cbx[$Tf]$Cxx method ($rm) r-uri ($ru)\n");
393 411
 ...
... ...
@@ -401,7 +419,7 @@ xbug("time $Cbx[$Tf]$Cxx method ($rm) r-uri ($ru)\n");
401 419
 
402 420
    This function can be used from ANY_ROUTE.
403 421
 
404
-   Example 1.15. xcrit usage
422
+   Example 1.16. xcrit usage
405 423
 ...
406 424
 xcrit("time $Cbx[$Tf]$Cxx method ($rm) r-uri ($ru)\n");
407 425
 ...
... ...
@@ -415,7 +433,7 @@ xcrit("time $Cbx[$Tf]$Cxx method ($rm) r-uri ($ru)\n");
415 433
 
416 434
    This function can be used from ANY_ROUTE.
417 435
 
418
-   Example 1.16. xalert usage
436
+   Example 1.17. xalert usage
419 437
 ...
420 438
 xalert("time $Cbx[$Tf]$Cxx method ($rm) r-uri ($ru)\n");
421 439
 ...