<p>Hi <a href="https://github.com/agranig" class="user-mention">@agranig</a>, <a href="https://github.com/kamailio-sync" class="user-mention">@kamailio-sync</a> @<br>
First, the module is still young, so the documentation may be incomplete. I will improve it asap</p>
<p>Second, my primary idea when started this module was to implement the same "destinations probing" mechanism found in dispatcher module, both in drouting & carrierroute modules. So instead of directly patching those modules (and duplicating the same code), I regroup all probing features in <em>keepalive</em> module that also expose a set of APIs (to be documented) to register a destination and be notified of destination status change.<br>
Following <a href="https://github.com/miconda" class="user-mention">@miconda</a> suggestions, it can also be used standalone</p>
<p><em>What does that mean?</em><br>
So currently you can use it in 2 ways:</p>
<ul>
<li>standalone: destinations to monitor are statically defined as module parameter then you can use is_alive() function or event route to react to destination state change</li>
<li>as "probing engine" for drouting module: by setting <em>enable_keepalive</em> drouting parameter, drouting destinations will be monitored by keepalive, and a call to do_routing() will ignore inactive destinations in the resultset.<br>
I will add examples to the documentation to make things clear, but you can already see a kamailio.cfg example for both case in this ml post: <a href="https://lists.kamailio.org/pipermail/sr-users/2017-March/096521.html">https://lists.kamailio.org/pipermail/sr-users/2017-March/096521.html</a></li>
</ul>
<p><em>What are the use cases and which problems does it solve?</em></p>
<ul>
<li>monitor remote trunks (allowing to take actions or trigger an alert when a destination is down)</li>
<li>ignore down destinations when routing a call</li>
</ul>
<p><em>Which mechanisms does it use (SIP, ICMP, others?)</em><br>
It is working the same way as dispatcher does, by regularly sending SIP OPTIONS to destinations</p>
<p>Hope I answered all your questions</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you were mentioned.<br />Reply to this email directly, <a href="https://github.com/kamailio/kamailio/issues/1082#issuecomment-296810631">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AF36ZX9jDNlM_rDd95T97Ya9WsOjxnzCks5rzQQegaJpZM4NEGEt">mute the thread</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/AF36ZR3B_kNtjR236rKXhheQD5ESWruOks5rzQQegaJpZM4NEGEt.gif" width="1" /></p>
<div itemscope itemtype="http://schema.org/EmailMessage">
<div itemprop="action" itemscope itemtype="http://schema.org/ViewAction">
  <link itemprop="url" href="https://github.com/kamailio/kamailio/issues/1082#issuecomment-296810631"></link>
  <meta itemprop="name" content="View Issue"></meta>
</div>
<meta itemprop="description" content="View this Issue on GitHub"></meta>
</div>

<script type="application/json" data-scope="inboxmarkup">{"api_version":"1.0","publisher":{"api_key":"05dde50f1d1a384dd78767c55493e4bb","name":"GitHub"},"entity":{"external_key":"github/kamailio/kamailio","title":"kamailio/kamailio","subtitle":"GitHub repository","main_image_url":"https://cloud.githubusercontent.com/assets/143418/17495839/a5054eac-5d88-11e6-95fc-7290892c7bb5.png","avatar_image_url":"https://cloud.githubusercontent.com/assets/143418/15842166/7c72db34-2c0b-11e6-9aed-b52498112777.png","action":{"name":"Open in GitHub","url":"https://github.com/kamailio/kamailio"}},"updates":{"snippets":[{"icon":"PERSON","message":"@gbour in #1082: Hi @agranig, @kamailio-sync @\r\nFirst, the module is still young, so the documentation may be incomplete. I will improve it asap\r\n\r\nSecond, my primary idea when started this module was to implement the same \"destinations probing\" mechanism found in dispatcher module, both in drouting \u0026 carrierroute modules. So instead of directly patching those modules (and duplicating the same code), I regroup all probing features in *keepalive* module that also expose a set of APIs (to be documented) to register a destination and be notified of destination status change.\r\nFollowing @miconda suggestions, it can also be used standalone\r\n\r\n_What does that mean?_\r\nSo currently you can use it in 2 ways:\r\n- standalone: destinations to monitor are statically defined as module parameter then you can use is_alive() function or event route to react to destination state change\r\n- as \"probing engine\" for drouting module: by setting _enable_keepalive_ drouting parameter, drouting destinations will be monitored by keepalive, and a call to do_routing() will ignore inactive destinations in the resultset.\r\nI will add examples to the documentation to make things clear, but you can already see a kamailio.cfg example for both case in this ml post: https://lists.kamailio.org/pipermail/sr-users/2017-March/096521.html\r\n\r\n_What are the use cases and which problems does it solve?_\r\n- monitor remote trunks (allowing to take actions or trigger an alert when a destination is down)\r\n- ignore down destinations when routing a call\r\n\r\n_Which mechanisms does it use (SIP, ICMP, others?)_\r\nIt is working the same way as dispatcher does, by regularly sending SIP OPTIONS to destinations\r\n\r\nHope I answered all your questions "}],"action":{"name":"View Issue","url":"https://github.com/kamailio/kamailio/issues/1082#issuecomment-296810631"}}}</script>