[Kamailio-Users] Why does Kamailio reply 408 when 'fr_inv_timer' expires?

Klaus Darilion klaus.mailinglists at pernau.at
Mon Aug 25 10:02:56 CEST 2008


Hi!

MAybe 408 is not the correct response code, but it is widely used. If 
you need a different response code IMO it would be better to make it 
configurable - e.g. as tm module parameter, and default is 408 (for 
backwards compatibility). I think this should be a easy patch.

regards
klaus

Iñaki Baz Castillo schrieb:
> Hi, when 'fr_inv_timer' expires Kamailio CANCELs the pending branches
> and reply "408 Request Timeout" to the UAC.
> Well, I wonder if 408 is appropiate. I think "480 User Unavailable" or
> "487 Cancelled" would be better:
> 
> I received those replies in other maillist:
> 
> "408 indicates transaction timeout. You have sent request to next hop
> and it has not responded back. If the gateway has not responded at all
> (Including 100 trying), 408 is appropriate. 480 is more of application
> usage meaning that the user is not available and would be appropriate
> if the gateway has at least send one provisional response i.e. 100,
> 180, 183..."
> 
> "408 is used consistently to mean IP-level timeout in sending a request
> from one element to another.  It is also defined to be returned by a
> UA when the time specified in "Expires" has been reached.  (In theory,
> two different error codes should be defined for these two situations,
> but that has not been done.)  However, in a ring-no-answer situation,
> it is more common for an upstream proxy to send a CANCEL to the
> UA/gateway, in which case the UA/gateway provides a 487 response to
> the INVITE."
> 
> 
> This last point suggest that Kamailio could do the following:
> 
> - If the proxy has received provisional responses from callee's then
> not send a 408 upstream since when the proxy sends CANCEL to UAS's it
> will receive some 487 and would return a 487 upstream.
> - If the proxy hasn't received provisional responses then this is a
> clear "408 Request timeout".
> 
> So a possibility is that Kamailio just reply a 408 in real timeouts
> and reply 487 when 'fr_inv_timer' expires (or just reply nothing since
> UAS's will generate the 487).
> 
> Opinions?
> 
> 
> 




More information about the sr-users mailing list