Module: kamailio
Branch: master
Commit: 5429a0ed51a04c484e1def93887b344b2d90379f
URL:
https://github.com/kamailio/kamailio/commit/5429a0ed51a04c484e1def93887b344…
Author: Kamailio Dev <kamailio.dev(a)kamailio.org>
Committer: The Root <root(a)kamailio.org>
Date: 2020-05-07T20:46:04+02:00
modules: readme files regenerated - keepalive ... [skip ci]
---
Modified: src/modules/keepalive/README
---
Diff:
https://github.com/kamailio/kamailio/commit/5429a0ed51a04c484e1def93887b344…
Patch:
https://github.com/kamailio/kamailio/commit/5429a0ed51a04c484e1def93887b344…
---
diff --git a/src/modules/keepalive/README b/src/modules/keepalive/README
index 150da0acdc..4437803128 100644
--- a/src/modules/keepalive/README
+++ b/src/modules/keepalive/README
@@ -55,8 +55,8 @@ Yasin CANER
1. Available Functions
- 1.1. add_destination(uri, owner, flags, [callback,
- [user_attr]])
+ 1.1. add_destination(uri, owner, flags, ping_interval,
+ [callback, [user_attr]])
1.2. Examples
@@ -324,7 +324,9 @@ Chapter 2. Developer Guide
1. Available Functions
- 1.1. add_destination(uri, owner, flags, [callback, [user_attr]])
+ 1.1. add_destination(uri, owner, flags, ping_interval, [callback,
+ [user_attr]])
+
1.2. Examples
The KeepAlive module provides an internal API to be used by other
@@ -336,10 +338,13 @@ Chapter 2. Developer Guide
1. Available Functions
- 1.1. add_destination(uri, owner, flags, [callback, [user_attr]])
+ 1.1. add_destination(uri, owner, flags, ping_interval, [callback,
+ [user_attr]])
+
1.2. Examples
-1.1. add_destination(uri, owner, flags, [callback, [user_attr]])
+1.1. add_destination(uri, owner, flags, ping_interval, [callback,
+[user_attr]])
This function registers a new destination to monitor. Monitoring of the
destination starts as soon as it returns with success (0 value).
@@ -354,6 +359,8 @@ Chapter 2. Developer Guide
* owner (string) - module name “owning” the destination (for
information purpose)
* flags (integer) - destination flags (unused for now, use 0 value)
+ * ping_interval (integer) - Pinging interval in seconds for this
+ destination
* callback (ka_statechanged_f, optional) - callback function,
executed on destination's state change.
The callback function is of type void (*ka_statechanged_f)(str
@@ -398,7 +405,7 @@ void my_callback(str uri, int state, void *user_attr) {
str dest = str_init("sip:192.168.10.21:5060");
str owner = str_init("mymodule");
-if (ka_api.add_destination(dest, owner, 0, my_callback, NULL) != 0) {
+if (ka_api.add_destination(dest, owner, 0, 60, my_callback, NULL) != 0) {
LM_ERR("can't add destination\n");
goto error;
}