We explore and extend a simple "Hello World" work flow that demonstrates the basics of web application infrastructure.
Presentation - Building Struts 2 Applications
How are web applications organized? What components does the framework add to the mix? Can traditional architectures be applied to web applications?
We overview the framework in broad strokes and setup essential software tools, so we can deploy a simple "hello world!" demonstration application that we extend in the main workshop.
- Web Application Infrastructure
- Struts Framework Components
- Model View Controller Architecture
- JPA enabled Java project
- Courseware source code (struts2-starter)
- Add web project capabilities
- Browse for Web Root, Create New Folder "WebRoot"
- Java 1.5 compatibility
- Open Windows Explorer window on struts2-starter
- Copy ((*.jar}} to WebRoot/WEB-INF/lib EXCEPT! struts2-spring-plugin.jar
- Copy web.xml to WebRoot/WEB-INF (overwriting any other version)
- Copy index.jsp and index.html to WebRoot/
- Copy struts.xml to src/ (with spring.xml and *.properties files)
- Run as MyEclipse Server Project (and deploy to Tomcat)
- Initial deployment may take some time
- Confirm that browser presents "MailReader Options" page
All code is provided.
- Added Web Application capabilities to an existing JPA project.
- Ran tests and opened a sample page via a Struts action.