[sr-dev] Outbound registrar.lookup() not ordering results by reg-id?
Daniel-Constantin Mierla
miconda at gmail.com
Mon Mar 4 17:06:27 CET 2013
Hello,
On 3/4/13 11:55 AM, Peter Dunkley wrote:
> Hi,
>
> I've been looking at caching the ruid and while reading the code I
> have not been able to understand how the contacts get correctly
> ordered for outbound.
>
> The contacts should be ordered so that those with the lowest reg-id
> are the first tried for each ;+sip.instance. However, I can't see any
> comparisons of reg-id anywhere (I've looked in usrloc, registrar, and
> the tm:t_..._contacts() functions).
>
> Have I missed something or is this (like the parallel forking issue
> Olle reported from SIPit) another outbound registrar issue that we
> need to fix?
location module keeps the records ordered by registration time, iirc. By
default, parallel forking does not care of Q value, will do branching at
once to all contacts.
If you need to take in consideration Q, then you have to use
t_load/next_contacts(). I assume it is the same for outbound and reg-id,
Juha implemented both of them.
In case the issues is something else, please refresh me with a link in
archive (or add to tracker) about the details after SIPit, I guess I
missed some discussions due to heavy traveling and may take me a while
to spot it in the history.
Cheers,
Daniel
--
Daniel-Constantin Mierla - http://www.asipto.com
http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
Kamailio World Conference, April 16-17, 2013, Berlin
- http://conference.kamailio.com -
More information about the sr-dev
mailing list