On Mon, 19 Jul 2004 11:57:56 +0800, Victor Tsang wrote: > Has anyone tried using Cache::Mmap in mod_perl?
That's what I wrote it for. My application uses Cache::Mmap to share caches between apache children and other processes. > I have written a perl code to test my design off apache, it works > very well, performance is great too, Glad to hear it. > but as soon as I move the code into mod_perl, the script fail and > report in error log > > Can't locate auto/Cache/Mmap/read.al in @INC I'm having trouble seeing how this could occur with the module correctly installed, since Cache::Mmap doesn't use AutoLoader (although DynaLoader does pull it in). In any case, if new() is defined (which is must be, since you're trying to call read()), then read() ought to be, too. I suspect one of the following: * your normal perl is different to your mod_perl perl, and the Cache::Mmap installation in the mod_perl perl is broken * you are calling Cache::Mmap::read() directly, and haven't loaded the module. I can't imagine why you'd do this, though, and your non- mod_perl version of this code wouldn't work, either. Check that the mod_perl copy of Cache::Mmap is installed correctly. Use CPAN's "force install" option if necessary, and make sure that you are using the perl appropriate to your mod_perl installation. -- Peter Haworth [EMAIL PROTECTED] "Do you count brain rot as a valid reason?" -- Larry Wall -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html