Return-Path: Delivered-To: apmail-new-httpd-archive@apache.org Received: (qmail 22917 invoked by uid 500); 2 May 2001 20:21:30 -0000 Mailing-List: contact new-httpd-help@apache.org; run by ezmlm Precedence: bulk Reply-To: new-httpd@apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list new-httpd@apache.org Received: (qmail 22832 invoked from network); 2 May 2001 20:21:21 -0000 Sender: gregames@Mail.MeepZor.Com Message-ID: <3AF06BCB.345078EA@remulak.net> Date: Wed, 02 May 2001 16:19:23 -0400 From: Greg Ames X-Mailer: Mozilla 4.75 [en] (X11; U; Linux 2.2.17-21mdk i686) X-Accept-Language: en MIME-Version: 1.0 To: new-httpd@apache.org Subject: Re: [PATCH] get threaded MPM to terminate References: <20010425140347.A1079@waka.ebuilt.net> <20010427202203.A1168@waka.ebuilt.net> <3AEDBDF8.2EE5D325@remulak.net> <20010430161845.D899@waka.ebuilt.net> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Spam-Rating: h31.sny.collab.net 1.6.2 0/1000/N "Roy T. Fielding" wrote: > > > > And why does each worker grab a mutex before checking the pipe of death? > > > All that a worker does is check to see if there is a character on the > > > pipe and, if so, it tells all of the workers to exit. So why does it > > > matter if more than one worker gets inside that exclusion zone? *shrug* > > > > yet another good question. I'll take a crack at it: > > > > when the parent decides to shut down or restart, it writes one character > > per process on the PoD. If multiple worker threads within a given > > process are allowed to each eat a character, some other process may not > > be woken up . This stall only occurs under very light loads (e.g. > > developers running tests). > > Wouldn't the same result be achieved by simply closing the pipe for > writing? Then when the children attempt to read they get an EOF, > regardless of how many attempt the read. This is assuming that the > parent opens a unique pipe of death per graceful restart, which > seems to be the case. > hmmmm...sounds reasonable, and sounds like less code too. Code that's not there can't break, and can't eat CPU either. I like it! Greg (who hasn't checked the unique pipe of death per restart situation)