httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ras...@madhaus.utcs.utoronto.ca
Subject Idea for new Configuration Directive
Date Thu, 09 May 1996 01:02:35 GMT
Definitely not a 1.1 thing, but perhaps something to think about for 1.2.

The MaxRequestsPerChild directive forces a respawn every given number
of requests.  That's very nice, but the reason to have this directive
is to release any bloated data space sitting around in the child process.
With the memory allocation pool system, it should be trivial to get an
idea of how large this data space is, or at least how much of it has
come from the Apache pool memory allocation.  So, it might make sense
to have a configuration directive which tells a child to respawn once
the allocated pool space goes beyond a certain high watermark.

As modules get more and more complex, this should help module writers
not completely lose their minds.  In my mod_php I currently am forced to
maintain 3 sub-pools within my session pool.  Each have different life-spans.
The first spans the entire session, the second is cleared every time I
clear the expression stack in my language, and the third is cleared on
every call to the yylex() parser.  I have put in a pool limiting directive
for the module so that web masters can limit the complexity of the PHP
scripts that users can write.  ie. if someone creates an infinite loop
that keeps lengthening a string, or someone recurses a function indefinitely.

How is this guarded against in mod_perl?  Will users who write bad Perl
scripts be able to bloat the httpd data space?

-Rasmus

Mime
View raw message