Hi all.
I'm using the MVC pattern for my current projects. In it, my servlet
is using a Front Controller type design pattern, finding out who requested
it (by using the REFERER header) and processing it before finding out what
the requested was (by using request.getServletPath()). It then determine the
navigation for the buttons on the next page using XML bindings into a
javabean.
This works fine for simple systems that have a fixed flow, but when
I added a href style click and jump navigation system. It starts to cause a
bit of problems. Not in the point and click itself but when you link in from
a separate browser window using the point and click system as well as when
there is a redirection to an error page. (using error page definitions in
web.xml).
Is there a better way to do the navigation? Can someone recommend a
design pattern that works better than the Front Controller? Or maybe show a
better example of how Front Controller can be used better? (The petstore
example is too simple to be of any use here). It works fine now but it's
starting to look like it could be a problem for someone maintaining it in
the future (yea i actually want to make it easy for someone else to maintain
;>) Something like what Struts does with the action forms is good but Struts
is way too much overhead for something that should be pretty simple.
The main issue is that this servlet should be "plug and playable"
into future systems with minimal changes. To do this currently, I am just
maintaining a separate XML config file for the 2 projects. I want to keep
the ease of that but have a cleaner controller servlet.
-Tim
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html