httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Aaron Bannert <aa...@clove.org>
Subject Re: cvs commit: httpd-2.0 STATUS
Date Fri, 26 Apr 2002 05:39:56 GMT
On Thu, Apr 25, 2002 at 10:36:25PM -0700, Brian Pane wrote:
> > +    * The worker MPM's fdqueue needs to be turned back into a FIFO.
> > +      Status: Aaron volunteers.
...
> > +    * The worker MPM should not accept more connections than it
> > +      currently has available workers. Instead, the listener thread
> > +      should block on a condition of the fdqueue such that it waits
> > +      until there are at least one idle worker before continuing
> > +      into the accept-loop.
> 
> Worker with those two changes would basically be the same as
> threadpool, right?

No, the LIFO->FIFO change is minor, and just changes the order in which
incoming requests are processed. The second change above (which is still
under debate IMHO) would be more of a design change, and would reduce
to zero the chances that an incoming request would "hang" while waiting
for other longer-standing requests to finish. The unfortunate side-effect
of preventing any "extra" accepts is that under high load we will not be
able to avoid the wait()/signal() interaction of the listener and worker
threads, and advantage we had before. (In the current implementation it
is possible that a worker thread complete its current request, return
to the queue, and immediately start processing another request without
ever having to wait for a signal.)

The threadpool looks like it's a stack, so that would now be different,
and the threadpool also has one condition variable per worker thread,
which is a much larger departure from the original worker design.

-aaron

Mime
View raw message