• Post Reply Bookmark Topic Watch Topic
  • New Topic

Central Navigation Servlet  RSS feed

 
Daniel Prene
Ranch Hand
Posts: 241
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is it possible to have a single servlet handle all navigation and act as the only gateway to pages? I want to do this for security, centralization, and easy logging. Check the users ID before forwarding them to a restricted page. Any help would be endlessly apreciated! Thnak you in advance for atleast reading this.

-D.P.
[ August 15, 2005: Message edited by: Daniel Prene ]
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, look up the "Front Controller" pattern.

You can also centralize a lot of this functionality with filters.
 
D Rog
Ranch Hand
Posts: 472
Linux Objective C Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"Front controller" is really good. I use it for 6 years for all my projects.
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I use Filters for most of what you are describing. Front Controller pattern is a (debtably) good pattern to use for page navigation but for security and logging, filters are the way to go.
 
Daniel Prene
Ranch Hand
Posts: 241
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you very much for all your help!
 
Daniel Prene
Ranch Hand
Posts: 241
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I've got the basics down from tutorials but I'm still not quite sure how to implement it in the real world... Could some one please post the code of a simple FC they have kicking around somewhere...?
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!