Igor Slepchin wrote:
> 
> "Adam B. Roach" wrote:
> >
> >    - 408 vs 504
> >
> >        408 is to be used when a request cannot be completed in the
> >            time specified in the "Expires" header.
> >
> >        504 is to be used when a proxy or other type of gateway
> >            doesn't receive a response from a next-hop node.
> 
> That sounds fine except that the current description of 408 is too
> restrictive. I think 408 should also be sent when a proxy gives up
> waiting for a final response due to some internal timeout (e.g., after a
> 1xx is received, INVITE transactions hang around forever unless some
> timeout is configured for them). 504 should only be used when no
> response whatsoever was received from a next hop.

Actually, I had a different interpretation of 504. 504 is when a proxy
tries to contact some other service, like a location server, and that
service does not respond. Thats why its a server failure; the other
service represents part of the operation of the server itself (many
folks include the location service within the proxy, for example). Thats
why its 500 class.

Also, I agree with Igor that 408 is used when a proxy gives up. Be
warned about this, however. Lets say a proxy forwards some request, gets
a 100. It then times out, and sends a 408. Unfortunately, the next hop
server then responds with a 300. Kind of too late... THe ideal solution
here is that when the timer expires, the proxy sends a CANCEL. This
should cause an almost immediate final response to the original request,
which can then be forwarded, or a 408 generated. This is safer, in the
sense that the server knows what the response from downstream is. Of
course, it gets more complicated if the CANCEL does not generate a
response to the original request. In this case, you are dealing with (1)
a UA which does not respond to the original request with 487 upon
receiving CANCEL, since you do not have to according to rfc2543, or (2)
some kind of downstream failure. In either case, you are much safer in
generating the 408. 

-Jonathan R.
-- 
Jonathan D. Rosenberg                       72 Eagle Rock Ave.
Chief Scientist                             First Floor
dynamicsoft                                 East Hanover, NJ 07936
[EMAIL PROTECTED]                     FAX:   (732) 741-4778
http://www.cs.columbia.edu/~jdrosen         PHONE: (732) 741-7244
http://www.dynamicsoft.com

Reply via email to