Re: Re: Validation class comments

From: Date: Thu, 30 May 2002 06:38:43 +0000
Subject: Re: Re: Validation class comments
References: 1 2 3 4 5 6  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-6637@lists.php.net to get a copy of this message
On Thu, 2002-05-30 at 03:10, Manuel Lemos wrote: > Hello, > > On 05/29/2002 03:14 PM, Peter Bowyer wrote: > > > > Wouldn't using PHP-Accelerator get around this problem? > > It's a trade-off. You trade loading/compiling overhead for memory. This > means that the compiled cached code will be using memory even if the > current script does not need them. In the end detaching validation code > from a main class will not make you gain anything because the code will > be occupying memory whether you use it or not. Let it be noted that the code is kept in _shared_ memory, and IMHO the tradeoff is well worth it. An Apache process that spends longer time processing a PHP-driven request will consume memory for a _longer period of time_ (using an OS that will actually return free()'d memory to the especially during peak times. YMMV of course, but my experience with ZA is that it always increases the performance of your site. That being said, I'm not a big fan of having lots of "trivial" classes wrapping lots of very simple code into a framework of overhead. - Stig

« previous php.pear.dev (#6637) next »