This assignment is the second iteration on the MessageBoard System that was implemented in the previous assignment. It consists of the following sections:
- HandlingUsersandGroups
- TestDrivenDevelopment
- UsingPatterns
- UsingWebPresentationPatterns
See documentation/SOEN387_Assignment_3.pdf for more details.
- Daniel Rinaldi - 40010464 (Team Leader)
- Anthony Van Voorst - 40001890
- Tiffany Ah King - 40082976
- Khadija Subtain - 40040952
All of the DDL required to create the database structure and fill it with any initial data is in 2 scripts located at database/db_structure.sql and database/db_initial_data.sql for the structure and initial data respectively.
Simply run these sql scripts (first the structure, then the data) and you should have the correct database setup.
Make a copy of the file located at src/main/webapp/WEB-INF/hibernate.cfg.example.properties and name the copy hibernate.cfg.properties.
This file will contain the local db credentials and you have to fill it in.
We used Eclipse (STS) as our IDE. This project is a basic dynamic web project that uses maven configuration.
- After cloning this repository, in order to setup the project in Eclipse, switch to Java EE perspective and right click in the project explorer view and select
import > import.... In the popup dialog, search for and selectExisting Projects into Workspace. In the next dialog window select the project folder and press finish. The project should show up as a dynamic web project in the project explorer view. - Right click on the project in the project explorer view and click
Configure > Convert to Maven Project. In the dialog that pops up select the project and hit finish. Now the project should have maven configuration setup. - Add the server run configuration. Go to
Run > Run Configuratrionsand create a new tomcat server configuration. - For some reason, when creating the server configuration, there is a dash (illegal) added as the defualt admin port for tomcat. Open the Servers view by going to
Window > Show View > Servers. Double click on the tomcat sever to be able to modify it. In the Overview tab, under thePortsaccordian menu, changeTomcat admin portto 0 or some other number other than a-. Save the file (ctrl+s) and close it. - You need to make sure that you have added tomcat server library to the classpath. Right click on the project in the project explorer view and click on
properties. In the project properties window, selectJava Build Path, click on theLibrariestab and make sure that Aapache Tomcat v9.0 is listed under Classpath. If not you will need to add it. Select "Classpath" then click on theAdd Librarybutton on the right and selectServer Runtime > Aapache Tomcat v9.0. - We use
/as the context root for this web project. So you need to right click on the project in the project explorer view and click onproperties. In the project properties window, selectWeb Project Settingsin the left hand menu. Change the context root property to/. - Add the web project to the server. Open the Servers view by going to
Window > Show View > Servers. Right click on the tomcat sever and selectAdd and Remove.... Add the web project to the configured list of projects and press finish. - Run the run configuration that you had setup in step 3. If everything was done correctly, you should gett a message in the console saying something like :
INFO: Server startup in [5982] milliseconds. Next open a web browser and navigate tohttp://localhost:{port_number}/.
| Grading Criteria | Points |
|---|---|
| Users and Groups Functionality | 20 |
| Processing Users andGroupsData | 15 |
| TDD | 15 |
| SeparatedInterface | 10 |
| UserManagerFactory | 10 |
| WebPresentationPatterns | 20 |
| Error Handling | 10 |
| Total | 100 |