From 124a5b16253926e748ba2724322b1b68f443c319 Mon Sep 17 00:00:00 2001 From: Daniel-Constantin Mierla Date: Sun, 28 Jul 2019 16:41:04 +0200 Subject: [PATCH] async: docs - use > instead of > in example for valid xml syntax - coherent white spacing --- src/modules/async/doc/async_admin.xml | 56 +++++++++++++-------------- 1 file changed, 28 insertions(+), 28 deletions(-) diff --git a/src/modules/async/doc/async_admin.xml b/src/modules/async/doc/async_admin.xml index c07beabfaba..0ad1d3b4fe2 100644 --- a/src/modules/async/doc/async_admin.xml +++ b/src/modules/async/doc/async_admin.xml @@ -94,7 +94,7 @@ modparam("async", "workers", 2) Enables millisecond timer for async_ms_sleep() and async_ms_route() functions. The integer value is the timer resolution in milliseconds. ms_timer = 1 enables 1 millisecond timer but generates higher load on the system. - ms_timer = 20 enables 20 ms timer. + ms_timer = 20 enables 20 ms timer. @@ -115,10 +115,10 @@ modparam("async", "ms_timer", 1)
Functions
- + <title> <function moreinfo="none">async_route(routename, seconds)</function> - - + + Simulate a sleep of 'seconds' and then continue the processing of the SIP request with the route[routename]. In case of internal errors, the function returns false, otherwise the function exits the execution of @@ -157,13 +157,13 @@ route[RESUME] { } ... - +
- + <title> <function moreinfo="none">async_ms_route(routename, milliseconds)</function> - - + + Simulate a sleep of 'milliseconds' and then continue the processing of the SIP request with the route[routename]. In case of internal errors, the function returns false, otherwise the function exits the execution of @@ -203,14 +203,14 @@ route[RESUME] { } ... - +
- + <title> <function moreinfo="none">async_sleep(seconds)</function> - - + + Simulate a sleep of 'seconds' and then continue the processing of SIP request with the next action. In case of internal errors, the function returns false. @@ -232,14 +232,14 @@ send_reply("404", "Not found"); exit; ... - +
- + <title> <function moreinfo="none">async_ms_sleep(milliseconds)</function> - - + + Simulate a sleep of 'milliseconds' and then continue the processing of SIP request with the next action. In case of internal errors, the function returns false. @@ -258,33 +258,33 @@ exit; ... route[REQUESTSHAPER] { - $var(res) = http_connect("leakybucket", - "/add?key=$fd", $null, $null,"$avp(delay)"); - $var(d) = $(avp(delay){s.int}); - if ($var(d) > 0) { + $var(res) = http_connect("leakybucket", + "/add?key=$fd", $null, $null,"$avp(delay)"); + $var(d) = $(avp(delay){s.int}); + if ($var(d) > 0) { # Delay the request by $avp(delay) ms async_ms_sleep("$var(d)"); if (!t_relay()) { sl_reply_error(); } exit; - } + } # No delay if (!t_relay()) { sl_reply_error(); } - exit; + exit; } ... - +
- + <title> <function moreinfo="none">async_task_route(routename)</function> - - + + Continue the processing of the SIP request with the route[routename] in one of the processes from core asynchronous framework. The core parameter async_workers has to be set to enable asynchronous @@ -304,7 +304,7 @@ route[REQUESTSHAPER] { async_workers=8 ... - + In case of internal errors, the function returns false, otherwise the @@ -339,7 +339,7 @@ route[RESUME] { } ... - +