On Tue, 15 Oct 2002, Perrin Harkins wrote:

> Josh Chamas wrote:
>
> >   Set MaxRequestsPerChild to 100 for applications that seem to leak
> >   memory which include Embperl 2.0, HTML::Mason, and Template Toolkit.
> >   This is a more typical setting in a mod_perl type application that
> >   leaks memory, so should be fairly representative benchmark setting.
>
>
> Maybe I'm more careful about memory growth than some people, but 100
> sounds a bit on the low side to me.  I use Apache::SizeLimit instead of
> MaxRequestsPerlChild, but I'm pretty sure every child serves more
> requests than that.  Did it seem to affect the performance numbers much?
>
> Incidentally, I hate to call this stuff "memory leaks", since it's
> usually just normal growth as memory gets used.  Calling it "leaks"
> implies that memory is being wasted as a result of mistakes with
> pointers or some such.  When people hear "memory leaks" they go running
> for stuff like Apache::Leak, thinking they can find some problem and fix
> it, which is usually not the case.

I'm fairly sure, FWIW, that Mason does not have any memory leaks, as of
1.12.  Pre-1.10 versions do have a _very_ slow memory leak, and 1.10 and
1.11 had that leak plus another, much nastier one.

Also FWIW, running Joshua's tests on my machine uniformly used about 1/3
to 1/4 as much RAM, with Mason, Template Toolkit and Apache::ASP.  I too
am running GNU/Linux, with a 2.4 kernel, on i386 hardware.  The only
difference in software was that I have Perl 5.8.0 installed, but I'd be
incredibly shocked if that explained the difference.

I've used Mason on a lot of machines, and I've found that processed
between 15-30MB (with mod_perl are relatively normal.  While this isn't
tiny, it isn't nearly as bad as the 60MB monster Josh found.

I'm actually pretty comfortable with Mason's memory usage because I think
that certain features it offers explain its memory use.  Basically, any
framework that offers filtering features on generated output will need to
store the entire output in memory before sending it, and I suspect this is
one thing I think has a big impact on Mason's memory usage.


-dave

/*==================
www.urth.org
we await the New Sun
==================*/


Reply via email to