![Page 1: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/1.jpg)
Advanced Software Engineering
Association for Computing Machinery
High School Competition System
Prof: Masoud Sadjadi Fall 2004
Second DeliverableBy: Prasad Tummala, Hien Nguyen, Jose
Ballesteros, Pablo A. Maurin, Bin Liu, Rafael Alpízar (Team
Four)
![Page 2: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/2.jpg)
Road Map Introduction Proposed Software Architecture System Decomposition
Component Diagram Deployment Diagram
Sub System Services Object Design
![Page 3: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/3.jpg)
Introduction Purpose
Build a system that will manage the ACM Programming Competition including the registration of teams on the web, and the game operations. The system will minimize errors inherent in manual operations, decrease the number of staff required to run the games, increase the communications with the participants prior to the event, and provide current and final results automatically.
![Page 4: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/4.jpg)
Introduction Design Goal
Usability User Friendly Response time Maintenance No dependencies to commercial software
component.
![Page 5: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/5.jpg)
Current Software Architecture Composed of two separate systems that
do not have any communications with each other.
1. Web based registration system Using ASP deployed on IIS With flat table database deployed on MS SQL
server
2. Game Management Web-based system deployed on Tomcat. Polling based notification of the judges that a
solution has been submitted.
![Page 6: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/6.jpg)
Proposed Software Architecture Two main subsystems
Web Based Subsystem Game Management Subsystem
Three other ancillary subsystems DB Access Subsystem E-mail subsystem Utility Subsystem
![Page 7: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/7.jpg)
Subsystem Decomposition Web Based Subsystem
Security Subsystem Team Information Management Subsystem Game Configuration Subsystem
![Page 8: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/8.jpg)
Subsystem Decomposition Game Management
Login Judge Interface Team Player Interface Score Board Game Server Scoring Game Communication Framework
![Page 9: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/9.jpg)
Proposed Software Architecture (Diagram)
«subsystem»TeamInformationManagment
«subsystem»Login&Security
«subsystem»DBaccess
«subsystem»Email
«subsystem»AccountManagement
«subsystem»ConfigureGameDetails
«subsystem»GameCommunicationFrameworks
«subsystem»GameServer
«subsystem»JudgeInterface
«subsystem»TeamInterface
«subsystem»ScoreBoard
«subsystem»Login
«subsystem»Score
«subsystem»Utility
![Page 10: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/10.jpg)
Hardware/Software Mapping Web Based System
Components WebBrowser Security Email ManageTeamServlet DBInterface Database
Deployed on two nodes: PC HostMachine
![Page 11: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/11.jpg)
Component Diagram For Web Subsystem
WebBrowser
Security ManageTeamServlet
Email DBInterface
Database
JDBC
![Page 12: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/12.jpg)
Deployment Diagram For Web Subsystem
: PC HostMachine
WebBrowserSecurity&Acctmgnt
ManageTeam Email
DBInterface
Database
![Page 13: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/13.jpg)
Hardware/Software Mapping Game Management Subsystem
Components Login TeamInterface JudgeInterface ScoreBoard GameServer Scoring GameCommunicationFramework DBInterface Database
Deployed on many nodes: 1 Game server n TeamPC m JudgePC 1 ScoreBoard
![Page 14: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/14.jpg)
Component Diagram For Game Management Subsystem
DBInterface
JudgeInterface
GameServer
Scoring
TeamInterface
ScoreBoard
Login
Database
JDBC
GameCommunicationFramework
![Page 15: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/15.jpg)
Deployment Diagram For Game Management Subsystem
TeamPC
ScoreBoardPCJudgePC
HostMachine
DBInterface
JudgeInterface
GameServer
Grader
TeamInterface
ScoreBoard
Database
GameCommunicationFramework
GameCommunicationFramework
GameCommunicationFramework
GameCommunicationFramework
![Page 16: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/16.jpg)
Object Design Trade-Off
Use MS-SQL Server vs. new database MS Access database vs. other database Java vs. other languages Java Messaging System (JMS) vs. Sockets Tomcat webserver vs. ISS Servlet & JSP vs. ASP
![Page 17: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/17.jpg)
Sub System Services & Object Design DB Access Subsystem
saveTeam saveAccount updateTeam updateAccount getTeam getAccount deleteTeam saveJudge getJudge deleteJudge setNewScore saveScore
![Page 18: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/18.jpg)
Sub System Services & Object DesignWeb-basedTeam Information
createNewTeam validateInfo updateTeam deleteTeam reportPay recordComment assignTeamID verifyTeam
![Page 19: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/19.jpg)
Subsystem Package Diagram
edu.fiu.cs.cen5011.acmcomp
.web
.security
.gameconfig
.teammgnt
.gamemanagement
.judge .team
.scoreboard
.scoring
.login .commframework
.db.util
.server
![Page 20: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/20.jpg)
Subsystems Dependencies
«subsystem»security
«subsystem»Team Information Management
«subsystem»Game Configuration
«subsystem»DB Access
«subsystem»Game Server
![Page 21: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/21.jpg)
DB Access Subsystem
Provides an interface to interact with the database and is responsible for all object relational mappings.
We solve this problem by applying the Façade Pattern.
![Page 22: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/22.jpg)
DB Access Subsystem
Part of querying a database involves setting up a connection to the database.
Creating and initializing the connection is the most expensive part of a database query.
Avoid creating a connection if at all possible. Allow all components in a process to use a single
global connection resource.
We solve this problem by applying the GangOfFour SingletonPattern.
![Page 23: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/23.jpg)
Singleton Pattern If a system only needs one instance of a class,
and that instance needs to be accessible in many different parts of a system, you control both instantiation and access by making that class a singleton.
Ensure a class only has one instance Provide a global point of access to it
The DBAccess class is made a Singleton, so the single connection will be shared by all components.
![Page 24: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/24.jpg)
ManageTeamServlet
doGet()doPost()deleteTeam()addTeam()updateTeam()
(from edu.fiu.cs.cen5011.acmcomp.web.teammgnt)
GameConfServlet
doGet()doPost()updateGameDetails()
(from edu.fiu.cs.cen5011.acmcomp.web.gameconfig)
LoginFilter
destroy()init()doFilter()
(from edu.fiu.cs.cen5011.acmcomp.web.securi ty)
DBAccess
instance : DBAccessconnection : Connection
DBAccess()instance()init()getTeamMember()updateTeamMember()removeTeamMember()storeTeamMember()storeTeamInfo()getTeamInfo()updateTeamInfo()removeTeamInfo()storeAccount()updateAccount()getAccount()removeAccount()storeSchool()updateSchool()getSchool()removeSchool()
ManageAccountServlet
doGet()doPost()createAccount()deleteAccount()updateAccount()
(from edu.fiu.cs.cen5011.acmcomp.web.securi ty)
![Page 25: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/25.jpg)
![Page 26: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/26.jpg)
Game Communication Framework Heart of Game Management Subsystem. Sits on top of JMS Provides abstraction layer for
Server Judge Team Scoreboard
![Page 27: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/27.jpg)
Game Communication Framework What is JMS?
A framework that provides mechanism for messaging between nodes in distributed network environment.
Provides Point-to-Point Publisher/Subscriber
![Page 28: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/28.jpg)
Software Architecture (Diagram)
TCP
JMS
Server
Game Communication Framework
Score Board
Team Interface
Judge Interface
GameManagement Subsytem Layers
![Page 29: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/29.jpg)
Game Communication Framework Class Diagram
Message
messageteamIDjudgeID
Message()getJudgeID()getTeamID()getMessage()setTeamID()setJudgeID()setMessage()
SolutionData
problemData : intdata : byte[]
SolutionData()getData()setData()getProblemNo()setProblemNo()
SolutionNotification
RESPONSE : int = 0AVAILABLE : int = 1REQUEST : int = 2ERROR : int = 3GRADED : int = 4team : longproblemNo : intsolutionNo : intcorrect : booleancomment : Stringdata : byte[]flag : int
SolutionNotification()getData()setData()getFlag()setFlag()getProblemNo()setProblemNo()getSolutionNo()setSoulitonNo()getTeam()setTeam()isCorrect()setCorrect()getComment()setComment()
Dispatcher
notifyJudges()receiveObjectFromJudge()receiveObjectFromTeam()sendMessage()receiveMessage()receiveStandings()sendStandings()
![Page 30: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/30.jpg)
Subsystems Dependencies
«subsystem»DBaccess
«subsystem»GameCommunicationFrameworks
«subsystem»GameServer
«subsystem»Score
![Page 31: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/31.jpg)
Game Server Subsystem Manages all relevant game events
Maintaining scores Generating final score report Keeps Game clock. Stores solutions for later retreival.
Sits on top of Game Communications Framework
Implements receiveSolutionNotification() callback method.
![Page 32: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/32.jpg)
Game Server Class Diagram
Solution
solutionTime : Datecorrect : booleangraded : booleanserverd : booleancancelled : booleanjudge : int
Solution()isCancelled()setCancelled()isCorrect()setCorrect()isGraded()setGraded()getJudge()setJudge()isServed()setServed()getSolutionTime()setSolutionTime()
Problem
problemNo : int
Problem()getProblemNo()setProblemNo()getSolutions()addSolution()getSolution()
Team
teamID
Team()getProblems()setProblems()addProblem()
ServerController
updateTeam()receiveSolutionNotification()
Judge
judgeID : long
setJudge()getJudge()
![Page 33: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/33.jpg)
Scorer Subsystem. Computes Standing for the game Rules of the game can potentially change Two Classes
Scorer class provides methods to the Server subsystem for computing standings
RulesEngine Interface defines the expected behavior of a RulesEngine to be used by the Scorer class.
![Page 34: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/34.jpg)
Scoring Class Diagram
BasicRulesEngine
ComputeStandings()
Future(from Logical View)
RulesEngine
ComputeStandings()
Scorer
rulesEngine : RulesEngine
Scorer()computeStandings()
Standings
teams : ArrayList
![Page 35: Advanced Software Engineering Association for Computing Machinery High School Competition System Prof: Masoud Sadjadi Fall 2004 Second Deliverable By:](https://reader036.vdocuments.mx/reader036/viewer/2022081515/56649e215503460f94b0d872/html5/thumbnails/35.jpg)
Thank you