<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);" class="elementToProof">
<span style="font-size:12pt;margin:0px;color:black;background-color:rgb(255, 255, 255)">Hello lhor,</span>
<div style="font-size:12pt;margin:0px;color:black;background-color:rgb(255, 255, 255)">
<br>
</div>
<div style="font-size:12pt;margin:0px;color:black;background-color:rgb(255, 255, 255)">
yes i will do some tests with cron to see if it suits well.</div>
<div style="font-size:12pt;margin:0px;color:black;background-color:rgb(255, 255, 255)">
<br>
</div>
<div style="font-size:12pt;margin:0px;color:black;background-color:rgb(255, 255, 255)">
the scenario is we have kamailio connected to redis database.</div>
<div style="font-size:12pt;margin:0px;color:black;background-color:rgb(255, 255, 255)">
<br>
</div>
<div style="font-size:12pt;margin:0px;color:black;background-color:rgb(255, 255, 255)">
redis store some configs for kamailio that we want to update (from redis to kamailio htable) let say every 5 hours.</div>
<div style="font-size:12pt;margin:0px;color:black;background-color:rgb(255, 255, 255)">
<br>
</div>
<div style="font-size:12pt;margin:0px;color:black;background-color:rgb(255, 255, 255)">
but if some reason we need to update some new config values from redis to kamailio immediatly. i want a way to trigger that as soon as we need it.</div>
<div style="font-size:12pt;margin:0px;color:black;background-color:rgb(255, 255, 255)">
<br>
</div>
<span style="font-size:12pt;margin:0px;color:black;background-color:rgb(255, 255, 255)">and <span style="font-weight:600;font-size:20px;margin:0px;color:rgb(50, 49, 48);background-color:white">evrexec<span style="margin:0px">  suits well for that i think.</span></span></span><br>
</div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>De :</b> Patrick Karton <patrickarton@hotmail.com><br>
<b>Envoyé :</b> mardi 16 août 2022 08:25<br>
<b>À :</b> Kamailio (SER) - Users Mailing List <sr-users@lists.kamailio.org><br>
<b>Objet :</b> RE: [SR-Users] proper way for infinite loop in event_route for evrexec module</font>
<div> </div>
</div>
<style type="text/css" style="display:none">
<!--
p
        {margin-top:0;
        margin-bottom:0}
-->
</style>
<div dir="ltr">
<div class="x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Hello lhor,</div>
<div class="x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div class="x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
yes i will do some tests with cron to see if it suits well.</div>
<div class="x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div class="x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
the scenario is we have kamailio connected to redis database.</div>
<div class="x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div class="x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
redis store some configs for kamailio that we want to update (from redis to kamailio htable) let say every 5 hours.</div>
<div class="x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div class="x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
but if some reason we need to update some new config values from redis to kamailio. i want a way to trigger that as soon as we need it.</div>
<div class="x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div class="x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
and <span style="color:rgb(50,49,48); font-size:20px; font-weight:600; background-color:rgb(255,255,255); display:inline!important">evrexec<span>  suits well for that i think.</span></span></div>
<div id="x_appendonsend"></div>
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="x_divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" color="#000000" style="font-size:11pt"><b>De :</b> sr-users <sr-users-bounces@lists.kamailio.org> de la part de Ihor Olkhovskyi <igorolhovskiy@gmail.com><br>
<b>Envoyé :</b> mardi 16 août 2022 07:09<br>
<b>À :</b> sr-users@lists.kamailio.org <sr-users@lists.kamailio.org><br>
<b>Objet :</b> Re: [SR-Users] proper way for infinite loop in event_route for evrexec module</font>
<div> </div>
</div>
<div>
<p>Patrick,</p>
<p><br>
</p>
<p>Maybe I'm a bit out of context, but could some external process like cron suits better for this kind of tasks than internal job?<br>
</p>
<p><br>
</p>
<div class="x_x_moz-cite-prefix">Le 14/08/2022 à 16:37, Patrick Karton a écrit :<br>
</div>
<blockquote type="cite"><style type="text/css" style="display:none">
<!--
p
        {margin-top:0;
        margin-bottom:0}
-->
</style>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Hello i would like to use the <b>evrexec </b>module to execute background jobs over <b>exec
</b>module <b>mainly because i want to be able to  trigger that route manually via rpc from time to time</b>.</div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
in the documentation its is stated we should use tasks that run forever and except using while loop i dont see another way.</div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
and i dont to want to disable <b>max_while_loops</b>. but if i disable it i will get error message like <b>runaway while (1091, 9): more then 100 loops.</b></div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
so is there another way to do it properly ? </div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Thanks.</div>
<br>
<fieldset class="x_x_moz-mime-attachment-header"></fieldset>
<pre class="x_x_moz-quote-pre">__________________________________________________________
Kamailio - Users Mailing List - Non Commercial Discussions
  * <a class="x_x_moz-txt-link-abbreviated" href="mailto:sr-users@lists.kamailio.org">sr-users@lists.kamailio.org</a>
Important: keep the mailing list in the recipients, do not reply only to the sender!
Edit mailing list options or unsubscribe:
  * <a class="x_x_moz-txt-link-freetext" href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users">https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users</a>
</pre>
</blockquote>
</div>
</div>
</body>
</html>