Front Controller PatternA Front Controller Pattern says that if you want to provide the centralized request handling mechanism so that all the requests will be handled by a single handler". This handler can do the authentication or authorization or logging or tracking of request and then pass the requests to corresponding handlers. Usage:
Benefits:
UML for Front Controller Pattern:Implementation of Front Controller Pattern:Step 1 Create a Login.html web page. Step 2 Create a FrontControllerServlet.java class which is a servlet and it may be a JSP page also. Step 3 Create a Success.jsp page. Step 4 Create a Error.jsp page. Step 5 Create a web.xml file. Output: Next Topic# |