Perrin Harkins wrote: > Stas Bekman wrote: > >> I think the idea was to have a special thread running whose only purpose >> is monitoring the pool of idle interpreters. > > > That sounds like a better solution.
The drawback is that there will be two different solutions for threaded and preforked mpms, meaning harder to do transitions. >> I believe that we can add a Perl space hook that sets a flag that >> condemns an interpreter to death. > > > The other problem, which might be harder, is to figure out how big a > particular interpreter is. The current implementations of > Apache::SizeLimit and GTopLimit cheat by asking the OS how big the > current process is. That won't work with threads. B::Size and B::TerseSize? Since the check can be run on the idle servers that shouldn't be a problem if they are slow. On the other hand since the idea is to always re-use the recently used interpreters, I'm not sure when there will be a chance to run checks on the interpreters on the top of the pool. Need to test how fast B::Size to decide whether it's feasible to run the check during the phase when the interpreter is being returned to the pool. Also it could be that we will need various schemes for pool management and for certain servers a round-robin solution will be more memory effective if we figure out that the interpreter memory usage measuring is slow and can be done only on the idle interpreters in the pool, because in that way fat interpreters can be killed. __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com