perl-modperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From penn...@aol.co.uk
Subject Re: load large data
Date Tue, 25 Sep 2007 08:16:23 GMT
Thank you.
I have added these directives in httpd.conf,

<Perl>
    use Mymodule;
    our $data = Mymodule->new;
</Perl>

Then I run bin/apachectl configtest,but got the errors,

Unknown type 'Mymodule' for directive data at 
/usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi/Apache2/PerlSectio
ns.pm line 192.\n

Please help.Thanks.



-----Original Message-----
From: frank@wiles.org
To: pennyyh@aol.co.uk
CC: modperl@perl.apache.org
Sent: Tue, 25 Sep 2007 1.42AM
Subject: Re: load large data

  On Mon, 24 Sep 2007 06:08:45 -0400
pennyyh@aol.co.uk wrote:

> Hello,
>
> I have a module,which loads large data into memory.
>
> my $data = Mymodule->new;
>
> this will take some ms to be finished.
>
> So I think I can create this object at startup time,and share the
> $data acrosss all apache child processes.
>
> Is it possible?How can I do it?

  Yeah you can do this in a <Perl> section at startup and
  your children can then use it.  I'm assuming here that the
  info in $data doesn't change or that you're ok with having
  to restart Apache to see the changes.

 -------------------------------------------------------
   Frank Wiles, Revolution Systems, LLC.
     Personal : frank@wiles.org  http://www.wiles.org
     Work     : frank@revsys.com http://www.revsys.com



________________________________________________________________________
Check out the new free AOL Email -- 2GB of storage and industry-leading 
spam and email virus protection.

Mime
View raw message