We now use mod_perl on our company's system, but for awhile (few years) we ran FastCGI. I love FastCGI. Static pages remain entirely static, without the overhead of calls to mod_perl hooks and without the memory bloat in each process caused by mod_perl (though much of the extra memory is shared).

FastCGI, if used correctly, allows for some fine tuning of your server. You can say, please dedicate 40 processes to this cgi, 2 processes to that cgi, etc. I would imagine, just from the layout of FastCGI, that it would run more quickly and take less memory thay mod_perl Apache::PerlRun. The latter has to go through it's hooks, share all loaded modules with anything else that is going to run (still require new modules if necessary), do the hit, and then tear down the package space when it is done. The FastCGI stays inside the isolated CGI and simply loops on connections. No tear down process, no other hooks, no shared modules are necessary.

That all said, mod_perl does handle a lot for you and you don't have to worry about fine tuning your webserver as everything is handled by an already running perl.

my @a=qw(random brilliant braindead); print $a[rand(@a)];


In reply to Re: Fast CGI or mod_perl by Rhandom
in thread Fast CGI or mod_perl by hakkr

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.