Struts Framework Architecture


The Struts Framework is a standard for developing well-architected Web applications. It has the following features:
  • Open source
  • Based on the Model-View-Controller (MVC) design paradigm, distinctly separating all three levels:
    • Model: application state
    • View: presentation of data (JSP, HTML)
    • Controller: routing of the application flow
  • Implements the JSP Model 2 Architecture
  • Stores application routing information and request mapping in a single core file, struts-config.xml
The Struts Framework, itself, only fills in the View and Controller layers. The Model layer is left to the developer.

Architecture Overview


All incoming requests are intercepted by the Struts servlet controller. The Struts Configuration file struts-config.xmlis used by the controller to determine the routing of the flow. This flows consists of an alternation between two transitions:
From View to ActionA user clicks on a link or submits a form on an HTML or JSP page. The controller receives the request, looks up the mapping for this request, and forwards it to an action. The action in turn calls a Model layer (Business layer) service or function.
From Action to ViewAfter the call to an underlying function or service returns to the action class, the action forwards to a resource in the View layer and a page is displayed in a web browser.



Enter your email address to get our daily JOBS & INTERVIEW FAQ's Straight to your Inbox.

Make sure to activate your subscription by clicking on the activation link sent to your email