[SR-Users] dispatcher confusion
Daniel-Constantin Mierla
miconda at gmail.com
Mon Feb 28 21:46:51 CET 2011
Hello,
On 2/28/11 5:29 PM, Klaus Darilion wrote:
> Hi!
>
> Every time I use the dispatcher(k) module I am confused again. Sometimes
> it seems that "probing" is a dedicated state, sometimes it seems that
> "probing" is done also in "active" state, but never in "inactive" state.
if you set the global parameter for probing, then no matter the state,
the pinging is done for all addresses.
If the module parameter is not set, only the destinations marked as
"probing" should be pinged.
In devel version I tried to sort out a bit these states, so we should
make it more sane and clear.
> IMO "probing" should only be a flag which indicates if OPTIONS should
> sent or not. If probing is successful, then the state should be
> "active". If probing is unsuccessful, then the state should be "inactive".
>
> Current behavior is very strange (ds_probing_mode(0)):
>
> --> startup state: A --> no probing
>
> kamctl fifo ds_set_state i 1 sip:....
> --> state: I --> no probing
>
> kamctl fifo ds_set_state a 1 sip:....
> --> state: A --> no probing
When ds_probing_mode==0, only if you set P flag to address will be pinged.
> calling 3 times ds_mark_dst("p")
> --> state: P --> probing (and dst is still loaded as last value into the
> dst_avp, why?)
>
> kamctl fifo ds_set_state i 1 sip:....
> --> state: I --> still probing
>
> kamctl fifo ds_set_state a 1 sip:....
> --> state: P (???) --> probing
>
> Thus, "ds_set_state a ..." does not set active, but probing if it was
> probing before. Strange.
>
> And as "inactive" does not stop probing when dst was in probing mode,
> the destination becomes automatically "active" if the probing succeeds.
inactive and probing are different flags. In devel I introduced new
state 'disabled' for cases when you want to "remove" an address from
destination list.
> And why is a destination in probing mode loaded into the dst_avp? Very
> weird.
If it is just probing and not inactive, then it is loaded as new dst.
> Is there a reason for this behavior?
IIRC, I think Carsten developed most of the probing mode, maybe there
was a reason behind current behavior.
Cheers,
Daniel
--
Daniel-Constantin Mierla
http://www.asipto.com
More information about the sr-users
mailing list