[Catalyst] two Catalyst flaws

Knut-Olav Hoven hovenko at linpro.no
Thu Jan 3 10:45:04 GMT 2008


On Thursday 03 January 2008 10:51:47 Fayland Lam wrote:
> please don't blame me if I'm wrong here. just point it out and I'll
> apologize :-)
>
> the first is to load all modules at beginning. I want to ask why? for
> $c->forward()? I think $c->model() can load when called. why I hate this
> is because it eats too many memory. one of my App has 80+ pm then it
> takes 150+M. I can't afford that!

I guess that's because Catalyst loads once and then stays loaded and handle 
your clients requests until you restart your server.

Sooner or later you will use all your modules, then why not load it all at 
once instead of using extra time on loading it later?

A normal "mistake" of managing web servers these days is to put tons of web 
applications onto one server and letting them fight over resources. Servers 
(and memory in particular) is a low cost factor (compared to development 
costs). Then why not give your lovely web application some GB's of memory?

>
> the second one is hard to use model in cron pl. I know we can do
> something like my $c = MyApp->prepare(); or Catalyst::Model::Adaptor
> (trust me, that's not so easy or fast)
> why I can't get a simple $c without function forward, without req,
> without res. just get $c->model and $c->cache like?
> I don't want this $c to load any Controller modules or View modules.
>
> anyway, Catalyst is a great framework. it ease our development a lot.
> Thanks for all your work, Catalyst Team!



-- 
Knut-Olav Hoven
Systemutvikler               mob: +47 986 71 700
Linpro AS                    http://www.linpro.no/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part.
Url : http://lists.scsys.co.uk/pipermail/catalyst/attachments/20080103/0c88d4d7/attachment.pgp


More information about the Catalyst mailing list