feedback on an approach
[prev]
[thread]
[next]
[Date index for 2005/02/09]
could someone who has worked w/mod perl longer than I have give me some=20=
feedback on this approach to webapps i've been using lately:
=95 the modperl handler creates a 'user' of the web app based on the=20
apache request
the 'user' handles all the session management, login, etc
my $user =3D new myApp::User( $r );
=95 the handler then creates a 'page' of the webapp as such
my $page =3D new myApp::Page( $user );
then calls it to render
my $outputHTML =3D $page->render()
the myApp::Page is a perl mod that pulls the request info off of the=20
user object, and correlates that to the user profile
everything is a perlmod that is pre-compiled. subclasses of=20
myApp::Page are the page content areas
It sounds crazy, and probably is.
playing around for a while, i realized that the dynamic stuff of the=20
pages for what i'm doing are 90% served out of a DB , repeatedly=20
called, and everything in terms of templating/standardizing really=20
inherits its design from the parent sections (perhaps its too oop=20
bringing it into visual layout too?).
i'd imagine that i'd get a decent performance gain by just doing all=20
of this as a perlmod that is preloaded at startup -- which is kind of=20
like what I've done with python webapps under the twisted framework=20
before.=
 |
feedback on an approach
Jonathan Vanasco 16:26 on 09 Feb 2005
|