[cgiapp] size of scripts and dependencies

Michael Peters mpeters at plusthree.com
Fri Sep 18 09:47:43 EDT 2009


On 09/18/2009 09:33 AM, P Kishor wrote:
> But, now that we are done
> comparing our overweight weight to a morbidly obese weight, how about
> CGI::App on its own? To my completely uninformed mind, loading 40,000+
> lines to create a small web page sounds like a lot... and, that
> doesn't even include the web server and the Perl interpreter!

But that's not what you tested. You tested Titanium which is not 
CGI::App. It's an opinionated framework based on CGI::App and it's 
plugins. If you just want to create something that makes "small web 
pages" then just load CGI::App and it's dependencies.

Also, let's look at those numbers:

  DBI - 7824
  CGI::Simple - 3900

That's 1/4 of all those lines just right there. And if you're going to 
use a database you need DBI. And if you're going to make a web app you 
need a CGI interface module (like CGI.pm or CGI::Simple) so I don't see 
a way to remove those.

Also, you're counting just raw lines which means you're counting 
comments and whitespace (which penalizes modules which are well 
commented). I'm not saying your criticism isn't valid, I'm just saying 
that your data is too flawed to support that criticism :)

-- 
Michael Peters
Plus Three, LP


More information about the cgiapp mailing list