httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chuck Murcko <>
Subject Re: alarm(0) problem
Date Fri, 18 Apr 1997 00:34:49 GMT
Roy T. Fielding wrote:
> >Isn't the situation when replying to a client essentially the same as
> >for the core server replying to a client? If anything, shouldn't there
> >only need to be a separate alarm for the proxy-as-client side of the
> >connection pair?
> That would be true only if the proxy receives the complete request
> (i.e., completes one timeout-covered period) before forwarding the
> request to the next hop, and completes receipt of the response before
> starting to forward it to the client.
> An easier way to think of it is that any timeout handler needs to restore
> the server to a pre-request state (closing all open connections and
> whatever else needs to be done).  Unfortunately, the main server timeout
> handler only knows about the client connection, and thus only works properly
> if that is the only thing that needs to be cleaned-up.  Thus, all places
> in the proxy where more things need to be cleaned must use a different
> timeout handler, or the server will be left in a bogus state.
> Our timeout code sucks big time, but we've known that for a few
> months now.  Is there a quick fix for 1.2?  You could just copy what
> is in http_main.c, change the names, and then add the global variables
> for the other things that might need cleaning.  It's yucky, but a
> proper table-based implementation of timeouts would take longer.
Hmmm. OK, I'm working on this now. I'm writing wrappers for the
purloined timeout code from http_main.c to allow cleaning up fds and
cache, as well. When it's working, I'll get a patch to the list and to
the folks having the hung connect problems. That'll be late tonight, I
Chuck Murcko
The Topsail Group, West Chester PA USA

View raw message