Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:30943 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 33610 invoked by uid 1010); 15 Jul 2007 01:01:22 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 33594 invoked from network); 15 Jul 2007 01:01:22 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 15 Jul 2007 01:01:22 -0000 Authentication-Results: pb1.pair.com smtp.mail=tijnema@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=tijnema@gmail.com; sender-id=pass; domainkeys=bad Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.132.251 as permitted sender) DomainKey-Status: bad X-DomainKeys: Ecelerity dk_validate implementing draft-delany-domainkeys-base-01 X-PHP-List-Original-Sender: tijnema@gmail.com X-Host-Fingerprint: 209.85.132.251 an-out-0708.google.com Received: from [209.85.132.251] ([209.85.132.251:44232] helo=an-out-0708.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 53/DD-05977-0E179964 for ; Sat, 14 Jul 2007 21:01:21 -0400 Received: by an-out-0708.google.com with SMTP id c18so164236anc for ; Sat, 14 Jul 2007 18:01:18 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=PpKV78k8jC18rfwPioDh4LL/YEKvWuPkfh1ph1JhEgwZUeq6d6lQjKSIYu4k9wUzFfsFk8hCnpVQznseM5IFv+Ruc3neLD8TIKJMVkK2/jmpvWpX0jIyMERdLPJBgJI3mW4lunQ1r1FeaV2yyVODZIGd4T7dYHlwEEi9wDdrJlc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=slWpPZbie9Pnocglo/qan2UCOF8wq9dC9qU8TNjcXxiFKX677FlOcsWQHBU3ytjQMwynYtMO1VSRAg2Rf6q4SkwCu7Az/NCTXOkauqQUCJQbXas9qqj2Rgq2zKSwTdNGT18+1NY66xZ/pAesz3CLt+C8RX+Fpd1qI8mEM88xzpk= Received: by 10.100.178.7 with SMTP id a7mr1638430anf.1184461277943; Sat, 14 Jul 2007 18:01:17 -0700 (PDT) Received: by 10.100.33.17 with HTTP; Sat, 14 Jul 2007 18:01:17 -0700 (PDT) Message-ID: Date: Sun, 15 Jul 2007 03:01:17 +0200 To: "Rasmus Lerdorf" Cc: "PHP Developers Mailing List" In-Reply-To: <4698F557.40006@lerdorf.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <469877B6.8010307@zend.com> <4698F557.40006@lerdorf.com> Subject: Re: [PHP-DEV] Apache handler with Multiple PHP versions From: tijnema@gmail.com (Tijnema) On 7/14/07, Rasmus Lerdorf wrote: > Tijnema wrote: > > On 7/14/07, Stanislav Malyshev wrote: > >> > The Apache2handler SAPI should be loaded first, and read the very > >> > first line of the PHP script to determine if a version is specified > >> > there. If not, the handler needs to load its default PHP version. If > >> > it is specified, it should try to load that version, and if it > >> > couldn't find or load that version, fall back to the default version > >> > and issue a warning. > >> > >> This means the engines would have to init/shutdown on each request, > >> which makes it as bad as CGI. > > Is that really a big problem? > > If you care at all about performance, yes. Well, I do, because if I don't, it won't be accepted anywhere. > > > And isn't that what Apache currently does? > > No, of course not. The whole point of the Apache module version of PHP > is to keep PHP in memory across requests and only call the MINIT and > MSHUTDOWN hooks on server startup and shutdown. Thank you for your very short manual on Apache Module. So, the only way I can implement this (without the performance hit), is by loading all PHP version at once at startup of apache, which will increase startup time, but that shouldn't be a problem. A more worrysome thing is the memory usage, I don't think that in the code is described how much memory it takes to load and startup PHP, can you give an estimate? > > Not to sound too elitist here, and this is directed just at you > personally, but if you are going to post to the internals list, you > should have some notion of how PHP works internally. We don't mind > people who don't work on the code posting here occasionally, but please > keep in mind that it is our primary means of communicating amongst the > people working on the code and lately it has gotten a bit hard to pick > out the useful stuff from the chatter. > > -Rasmus > Thank you for clarifying the intention of this list, as I had another intention of it. So, I'll start studying (docs of) the code soon. I think it would be the best to actually work with the core too, so I think I'll just start to implement this idea while learning how everything works. Tijnema