Re: [cgiapp] How to lazy-load runmodes

2011-05-25 Thread Ron Savage
Hi gvim On Tue, 2011-05-24 at 20:28 +0100, gvim wrote: On 24/05/2011 19:08, Joshua Miller wrote: Completely agree and second this. If you have a choice of FastCGI or CGI, just go FastCGI. If you're concerned about the differences in memory usage and such, you're free to benchmark them,

Re: [cgiapp] How to lazy-load runmodes

2011-05-25 Thread gvim
On 25/05/2011 07:37, Ron Savage wrote: I don't run Apache anymore. I run nginx and proxy cgi-bin/ to mini-httpd. A 'weird error' won't be in those programs, it'll be in your code, no matter how hard you find that to believe :-))). It's a classic symptom of using a global variable(s),

Re: [cgiapp] How to lazy-load runmodes

2011-05-25 Thread Ron Savage
Hi gvim On Thu, 2011-05-26 at 01:42 +0100, gvim wrote: On 25/05/2011 07:37, Ron Savage wrote: I don't run Apache anymore. I run nginx and proxy cgi-bin/ to mini-httpd. A 'weird error' won't be in those programs, it'll be in your code, no matter how hard you find that to believe :-))).

Re: [cgiapp] How to lazy-load runmodes

2011-05-24 Thread gvim
On 24/05/2011 05:27, Ron Savage wrote: Hi gvim You don't have to use or load them all. If you adopt CGI::Application::Dispatch and a MVC structure, only 1 controller module gets loaded, and hence only the run modes in that module get loaded. But if I have only 1 controller module which

Re: [cgiapp] How to lazy-load runmodes

2011-05-24 Thread gvim
On 24/05/2011 06:23, Joshua Miller wrote: On Mon, May 23, 2011 at 11:15 PM, gvimgvi...@gmail.com wrote: isn't there a huge startup penalty... Not if you're using FastCGI, PSGI + something like FastCGI or mod_perl, mod_perl, Starman or any other persistent perl thing. In those cases, it loads

Re: [cgiapp] How to lazy-load runmodes

2011-05-24 Thread Michael Peters
On 05/24/2011 07:34 AM, gvim wrote: Whilst a FastCGI solution improves startup time it doesn't address the memory footprint. I'm comparing deploying an app with CGI::Application vs. CGI with separate Perl scripts on a VM with a modest amount of mempory. From the what I'm learning about

Re: [cgiapp] How to lazy-load runmodes

2011-05-24 Thread Joshua Miller
On Tue, May 24, 2011 at 9:18 AM, Michael Peters mpet...@plusthree.comwrote: On 05/24/2011 07:34 AM, gvim wrote: Whilst a FastCGI solution improves startup time it doesn't address the memory footprint. I'm comparing deploying an app with CGI::Application vs. CGI with separate Perl scripts on

[cgiapp] How to lazy-load runmodes

2011-05-23 Thread gvim
If I have a collection of, say, 15 fairly lengthy Perl scripts and I convert them into a CGI::Application app with 15 runmodes isn't there a huge startup penalty since my app must now load the code for all 15 runmodes prior to dispatch? Is there a way to lazy-load my runmodes? Although I have

Re: [cgiapp] How to lazy-load runmodes

2011-05-23 Thread Ron Savage
Hi gvim On Tue, 2011-05-24 at 04:15 +0100, gvim wrote: If I have a collection of, say, 15 fairly lengthy Perl scripts and I convert them into a CGI::Application app with 15 runmodes isn't there a huge startup penalty since my app must now load the code for all 15 runmodes prior to

Re: [cgiapp] How to lazy-load runmodes

2011-05-23 Thread Joshua Miller
On Mon, May 23, 2011 at 11:15 PM, gvim gvi...@gmail.com wrote: If I have a collection of, say, 15 fairly lengthy Perl scripts and I convert them into a CGI::Application app with 15 runmodes isn't there a huge startup penalty since my app must now load the code for all 15 runmodes prior to