in reply to importing functions with "PerlModule" Apache directive

If you are trying to move out the use statements from the code into the Apache config, I don't think it makes much sense. A goal of mod_perl is to load the required modules at Apache startup, which will improve performance and memory use. The subsequent use at the actual Perl script costs very little -- it only imports the module's functions into the script's namespace.

Besides, if you want to erase those use statements from the actual scripts, it will be a maintenance nightmare should any of the scripts ever have to be moved.

Replies are listed 'Best First'.
Re^2: importing functions with "PerlModule" Apache directive
by acanfora (Novice) on May 09, 2012 at 12:48 UTC
    I agree about the maintenance issue. In this case the application being developed is strictly tied up with the system and its own peculiar configuration.