Sean Davis wrote:
I have an application that I think would be well-served by moving over to a mod_perl environment and would like to proceed in that direction. I was hoping someone might be willing to share a few step-by-steps or a couple of good links as to how to go about that. I have an Apache server with mod_perl running. I use a couple of DBI connections, CGI::Session (the plugin), and TT as the template engine. As far as I know, I have no global variables defined.
I would start off by running your script (hopefully unchanged) under Apache::Registry. If that doesn't work then maybe Apache::PerlRun.
I would definitely check out http://perl.apache.org/docs/1.0/guide/getwet.html#Porting_Existing_CGI_Scripts_to_run_under_mod_perlThen, you should be able to use Apache::DBI as a drop in replacement for DBI to use cached connections between requests.
If it's a large app, this may be sufficient and trying to port it to use the native Apache::* modules may be more headache than it's worth if you're using CGI.pm. I would however strongly suggest that you consider the Apache::* modules for you next project (along with CGI::Application::Plugin::Apache and CGI::Application::Dispatch - a shameless plug :)
Let us know how that goes. I'm sure more people could use encouragement as others enter the mod_perl world.
Good Luck!
--
Michael Peters
Developer
Plus Three, LP
---------------------------------------------------------------------
Web Archive: http://www.mail-archive.com/suppressed/
http://marc.theaimsgroup.com/?l=cgiapp&r=1&w=2
To unsubscribe, e-mail: suppressed
For additional commands, e-mail: suppressed
Mail converted by mhonarc 2.6.15
This archive provided courtesy of JSW4.NET, Internet Hosting Services for Small Business.