<div dir="ltr">Good point - I'll do that</div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, 2 Dec 2020 at 16:33, Liviu Chircu <<a href="mailto:liviu@opensips.org">liviu@opensips.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
  
    
  
  <div>
    <div>On 02.12.2020 18:16, Mark Allen wrote:<br>
    </div>
    <blockquote type="cite">Thanks
      so much for your help Liviu. In the end, I used the $shv()
      approach you suggested. It worked like a dream! :-)
      <div><br>
      </div>
      <div>
        <div>In opensips.cfg:</div>
        <div><br>
        </div>
        <div><font face="monospace">    loadmodule "cfgutils.so"<br>
                    modparam("cfgutils", "shvset", "cacheValid=i:0")<br>
          </font></div>
        <div><font face="monospace"><br>
          </font></div>
        <div><font face="monospace">    route{<br>
          </font></div>
        <div><font face="monospace">        if ($shv(cacheValid) == 0) {</font></div>
      </div>
    </blockquote>
    <p><tt>Glad it worked!  Depending on the volume of traffic flowing
        through your instance, maybe it would be better to perform the
        "is cache valid" check within a timer route [1] at a frequency
        of your choosing, rather than on each SIP request.</tt></p>
    <p><tt>[1]:
        <a href="https://www.opensips.org/Documentation/Script-Routes-3-2#toc8" target="_blank">https://www.opensips.org/Documentation/Script-Routes-3-2#toc8</a></tt><br>
    </p>
    <pre cols="72">-- 
Liviu Chircu
<a href="http://www.twitter.com/liviuchircu" target="_blank">www.twitter.com/liviuchircu</a> | <a href="http://www.opensips-solutions.com" target="_blank">www.opensips-solutions.com</a></pre>
  </div>

</blockquote></div>