Leon Brocard posted this minimalist Apache configuration that covers Catalyst and FastCGI.
I keep seeing more people not using mod_perl. Leon calls mod_perl "very bloated." Thoughts?
To my mind mod_perl and FastCGI aren't really the same thing. FastCGI is more comparable to running Apache::Registry, or Apache::PerlRun under mod_perl. In other words, just touching the surface of what mod_perl gives you.
The true power of running mod_perl lies in the access that it provides to the underlying Apache API. There are tons of things you can do using mod_perl that you can't do running FastCGI. Things like Input and Output filters, type handlers, true access, authen and authz handlers (or anything else you might want to do during the the proper phase.
I've heard this kind of comment before and it's just a mis-perception, I believe. The size of mod_perl processes comes from the perl code you load, which is the same with FastCGI. It doesn't load things you don't ask for and running it in with a reverse proxy (as all sites of significant size should) makes the process model the same as FastCGI.
Right on, jsut and Perrin. The people who declare mod_perl bloated probably don't need or use the more advanced (read: fun) features.
Here's a suggestion: If you're going to compare mod_perl and FastCGI, don't use a trivial CGI script as the basis for your test. Use a real-world example that involves authentication and, if you want to really see the potential of mod_perl, integration of non-perl content.
Actually, there are some good reasons to go the FCGI route:
1) Your Webhost supports FCGI, but not mod_perl.
2) Your Web Apps don't need the level of Apache integration that mod_perl provides.
3) You don't want to/need to mess with mod_perl's complexities - I've run a site using the light/heavy dual Apache with reverse proxy and it requires a bit of work to get right. Not mention mod_perl's interactions with non-mod_perl aware scripts can be...frustrating.
I run mod_perl and love it. It's just not the right tool for every job and every situation.
This page contains a single entry by Andy Lester published on December 7, 2007 1:15 PM.
How to: Tell your users they are not worth your time was the previous entry in this blog.
Share your dotfiles and check out others is the next entry in this blog.
Find recent content on the main index or look in the archives to find all content.