<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 5.5.2657.82">
<TITLE>RE: [Serusers] how to sort data retrieved from avp_db_load in avpops module</TITLE>
</HEAD>
<BODY>

<P><FONT SIZE=2>Hi Juha,</FONT>
</P>

<P><FONT SIZE=2>&nbsp;&nbsp;&nbsp; I thought that LCR module is only used to try a list of PSTN gateways or SIP proxies so I didn't look for a multi-forwarding solution using this module. Maybe I should take a look at it. Could you please confirm that with this module ser can load a list of destinations for each SIP request based on TO, FROM or RURI of the sip message? Thank you for your help.</FONT></P>

<P><FONT SIZE=2>Minh</FONT>
</P>

<P><FONT SIZE=2>-----Message d'origine-----</FONT>
<BR><FONT SIZE=2>De: Juha Heinanen</FONT>
<BR><FONT SIZE=2>A: PHAN, Quang-Minh (Docteur Ordinateur)</FONT>
<BR><FONT SIZE=2>Cc: 'serusers@lists.iptel.org'</FONT>
<BR><FONT SIZE=2>Date: 20/03/2005 14:04</FONT>
<BR><FONT SIZE=2>Objet: [Serusers] how to sort data retrieved from avp_db_load in avpops module</FONT>
</P>

<P><FONT SIZE=2>PHAN, Quang-Minh (Docteur Ordinateur) writes:</FONT>
</P>

<P><FONT SIZE=2>&nbsp;&gt;&nbsp;&nbsp;&nbsp;&nbsp; I want to implement serial forking with avpops module and I have</FONT>
<BR><FONT SIZE=2>this</FONT>
<BR><FONT SIZE=2>&nbsp;&gt; problem. The set of destinations for each user is stored in a</FONT>
<BR><FONT SIZE=2>database and I</FONT>
<BR><FONT SIZE=2>&nbsp;&gt; use apv_db_load to load it. However, I couldn't find a way to sort</FONT>
<BR><FONT SIZE=2>them in</FONT>
<BR><FONT SIZE=2>&nbsp;&gt; the right order. For example, I cant tell SER to try destination A</FONT>
<BR><FONT SIZE=2>before B,</FONT>
<BR><FONT SIZE=2>&nbsp;&gt; then C because there is no way to specify this in the database. </FONT>
</P>

<P><FONT SIZE=2>if you use location table to store the destinations, then you can use</FONT>
<BR><FONT SIZE=2>lcr module to implement serial forking according to q value.</FONT>
</P>

<P><FONT SIZE=2>&nbsp;&gt; Another</FONT>
<BR><FONT SIZE=2>&nbsp;&gt; feature I want to implement is to allow a client to specify a timeout</FONT>
<BR><FONT SIZE=2>for a</FONT>
<BR><FONT SIZE=2>&nbsp;&gt; destination. Eg. Try A for x seconds, then try B for y seconds, then</FONT>
<BR><FONT SIZE=2>&nbsp;&gt; try C.</FONT>
</P>

<P><FONT SIZE=2>lcr module has a timer variable that is used to timeout all but the</FONT>
<BR><FONT SIZE=2>last destination.</FONT>
</P>

<P><FONT SIZE=2>-- juha</FONT>
</P>

</BODY>
</HTML>