<html>
  <head>
    <meta content="text/html; charset=windows-1252"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    $var(x) keeps the value in the context of the process. t_continue()
    doesn't delegate route execution to other processes, it is executed
    in the context of same process. So, yes, it is also the same for
    rtimer processes. Actually, I can bet more for rtimer case, for
    evapi, I will need to double check, because the libev might create
    some extra threads around...<br>
    <br>
    In other words,
    <meta charset="utf-8">
    t_continue(tindex, tlabel, rtname) is like:<br>
    <br>
    set_active_transaction(tindex, tlabel);<br>
    route(rtname);<br>
    <br>
    t_suspend() is the one that parks the transaction and you can resume
    processing it with t_continue() in other process, so if you set
    $var(x) before t_suspend(), don't expect proper value at
    t_continue().<br>
    <br>
    Cheers,<br>
    Daniel<br>
    <br>
    <div class="moz-cite-prefix">On 25/05/15 12:35, Alex Balashov wrote:<br>
    </div>
    <blockquote cite="mid:5562FAD9.3010503@evaristesys.com" type="cite">Daniel,
      <br>
      <br>
      On 05/25/2015 06:32 AM, Daniel-Constantin Mierla wrote:
      <br>
      <br>
      <blockquote type="cite">yes, it is safe to use $var(x) to pass
        values between the block
        <br>
        calling t_continue() and the route executed by t_continue().
        <br>
      </blockquote>
      <br>
      Why is that, when the scope of $var() variables is, as I
      understand it, maintained only by a given SIP receiver thread?
      <br>
      <br>
      Regardless, is this true only when async task workers are used, or
      is this also true with other mechanisms, like resuming suspended
      transactions in rtimer threads?
      <br>
      <br>
    </blockquote>
    <br>
    <pre class="moz-signature" cols="72">-- 
Daniel-Constantin Mierla
<a class="moz-txt-link-freetext" href="http://twitter.com/#!/miconda">http://twitter.com/#!/miconda</a> - <a class="moz-txt-link-freetext" href="http://www.linkedin.com/in/miconda">http://www.linkedin.com/in/miconda</a>
Kamailio World Conference, May 27-29, 2015
Berlin, Germany - <a class="moz-txt-link-freetext" href="http://www.kamailioworld.com">http://www.kamailioworld.com</a></pre>
  </body>
</html>