perl-modperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Perrin Harkins <per...@elem.com>
Subject Re: Using PerlSetVar in virtual environments
Date Fri, 02 Jun 2006 17:42:49 GMT
On Fri, 2006-06-02 at 10:34 -0700, Will Fould wrote:
> I'm wondering if my trouble is from my use of 'require'

Most likely.  You didn't show us what's in the required file, but I'm
guessing it just sets a bunch of variables.  If you really want this to
load that file on every request, change require to "do" instead.

A better way is to load all the data into a hash and then use something
from the PerlSetVar as an index to tell which data in the hash to use
for this request.  That avoids reloading the file over and over.

- Perrin


Mime
View raw message