Perl: the Markov chain saw | |
PerlMonks |
mod_perl & TT2 Architectureby tadamec (Beadle) |
on May 24, 2004 at 23:43 UTC ( [id://356084]=perlquestion: print w/replies, xml ) | Need Help?? |
tadamec has asked for the wisdom of the Perl Monks concerning the following question: Greetings, Monks! I have a question regarding the architecture of web applications, particularly under mod_perl using the Template Toolkit. In the past, applications I've worked on have ended up a jumble of application and presentation logic. I'd like to avoid the trap this time. I was wondering if I could get some input from the rest of you out there who've worked with this combination for effective design strategies. I've been tasked to come up with an administration area for an "E-Business" and, possibly, redo their entire front end and shopping cart. The current application is written in ASP and is a nightmare of embedded HTML and sometimes-global sometimes-local variables. Making a minor tweak sometimes takes a week or two. In order to make the site easily expandable, and keep related business logic together, I thought I'd make a generalized Apache handler to take care of sessions and user authentication, and then come up with some sort of dispatching scheme to will map URLs to Perl modules and methods. For example, "http://www.example.com/login" would be handled by the generalized Apache handler, and methods like "http://www.example.com/foo/bar" would be handled by a call to Foo->bar(). Before I commit to this radical change, I'd like to know if anybody has done something similar and, if so, how well did it work out for you? Is there a better method? Am I entirely off base? Thanks for you input!
Back to
Seekers of Perl Wisdom
|
|