I don;t recall the join ever being done during shutdown. I am reasonably certain that
what
Paul is doing is the right thing to do.
Bill
----- Original Message -----
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, April 13, 2001 4:37 PM
Subject: Re: Need access to apr_sigwait from threaded mpm.
>
> > > We had the join logic in the code for a while, and we removed it at some
> > > point, although I can't remember why. Please take a look in the CVS logs.
> > > I am a bit busy today, becuase Covalent is moving offices (need more
> > > space), so I am having a hard time actually doing work right now. The
> > > easiest way to do this in my mind, though, is to have each thread
> > > decrement a counter as it dies. The core knows how many threads it has,
> > > so we know when they have all died.
> >
> > This is what the code currently does. worker_thread increments/decrements
> > the worker_thread_count variable inside a mutex. The problem seems to be
> > the window at the end of the worker_thread after is has decremented and
> > released the mutex and before it exits. I am seeing cases where the child_main
> > process thinks that worker_thread_count == 0, but threads haven't exited
> > yet. If child_main exits, then threads are orphaned. That is the reason
> > that some after-thread-exit processing (like a join) needs to happen.
>
> Okay, that makes sense. Synchronization is a real PITA. I still want to
> understand why the join stuff was removed before we put it back in though.
> I believe that logic was in either mpmt_pthread.c a while ago, or it was
> from back when Apache 2.0 was called apache-apr.
>
> Ryan
>
> >
> > I will look through cvs for the deleted join logic. Was it in the signal.c,
> > the mpms, or somewhere else (you can say you don't remember - just thought
> > I'd ask to save time).
> >
> > Thanks.
> >
> > --
> > Paul J. Reder
> > -----------------------------------------------------------
> > "The strength of the Constitution lies entirely in the determination of each
> > citizen to defend it. Only if every single citizen feels duty bound to do
> > his share in this defense are the constitutional rights secure."
> > -- Albert Einstein
> >
> >
>
>
> _______________________________________________________________________________
> Ryan Bloom [EMAIL PROTECTED]
> 406 29th St.
> San Francisco, CA 94131
> -------------------------------------------------------------------------------
>