httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dean Gaudet <dgau...@arctic.org>
Subject Re: cvs commit: apache-1.3/src/main http_main.c
Date Mon, 04 Jan 1999 23:23:02 GMT


On Mon, 4 Jan 1999, Marc Slemko wrote:

> On Mon, 4 Jan 1999, Dean Gaudet wrote:
> 
> > On Sun, 3 Jan 1999, Marc Slemko wrote:
> > 
> > > Yea, I don't know that this is a good thing to do by default either.
> > > However, I keep running into situation after situation where something
> > > screws this up.  Perhaps the code I'm dealing with is too horrible, but
> > > I really don't think that is the case.
> > > 
> > > I would go for a compile time (yuck yuck, compiletime bad) or runtime
> > > config option to enable a "reset alarm and handler" call at the end of
> > > each response, but default to off.
> > 
> > My other suggestion would probably work better though -- use SIGUSR2
> > between parent and child, and stick in a SIGALRM handler which logs "hey
> > there, wow, I got a SIGALRM, you've got a screwed up module!"  Then you'll
> > find out if in fact you do have the bug.  (And if you install the handler
> > with SA_RESTART then you don't even need to fix up anything.) 
> 
> Mmm.  Maybe.
> 
> You still have to keep reinstalling the SIGALRM handler though, since
> otherwise some wonderful code will install its own handler then reset it
> to default, ie. kill the thing.  That does give you a nice log saying
> "oops, this child exited on SIGALRM" but hurts anything it may not be
> doing.

OK, once you get the first SIGALRM like this, turn on your "reset alarm
and handler" feature.  You could even put the enabler for it into the
global scoreboard, since we really only care about it in OPTIMIZE_TIMEOUTS
-- which has a shared mem scoreboard.

Dean


Mime
View raw message