reliable service scheduler in a distributed web service environment

40
Reliable Service Scheduler Reliable Service Scheduler in a Distributed Web in a Distributed Web Service Environment Service Environment John Bouchard John Bouchard Brad Tiffany Brad Tiffany Ethan Towne Ethan Towne Daniel Richard Daniel Richard

Upload: hannah-long

Post on 02-Jan-2016

33 views

Category:

Documents


0 download

DESCRIPTION

Reliable Service Scheduler in a Distributed Web Service Environment. John Bouchard Brad Tiffany Ethan Towne Daniel Richard. Are We Done Yet?!?!?!. Recap of Project. Service scheduler in a web service environment. Application Server. Applications. Two Applications QB Rating Calculator - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Reliable Service Scheduler in a Distributed Web Service Environment

Reliable Service Scheduler in a Reliable Service Scheduler in a Distributed Web Service Distributed Web Service

Environment Environment

John BouchardJohn Bouchard

Brad TiffanyBrad Tiffany

Ethan TowneEthan Towne

Daniel RichardDaniel Richard

Page 2: Reliable Service Scheduler in a Distributed Web Service Environment

22

Are We Done Yet?!?!?!Are We Done Yet?!?!?!

Page 3: Reliable Service Scheduler in a Distributed Web Service Environment

33

Recap of ProjectRecap of Project

Service scheduler in a web service Service scheduler in a web service environmentenvironment

ApplicatioApplication n

ServerServer

Page 4: Reliable Service Scheduler in a Distributed Web Service Environment

44

ApplicationsApplications

Two ApplicationsTwo Applications QB Rating CalculatorQB Rating Calculator Base Conversion ToolBase Conversion Tool

Two VersionsTwo Versions Windows ApplicationWindows Application PDA ApplicationPDA Application

Page 5: Reliable Service Scheduler in a Distributed Web Service Environment

55

Application DesignApplication Design

Create Windows ApplicationCreate Windows Application Redesigned UI for PDARedesigned UI for PDA Client-Server ModelClient-Server Model

PDA Applications use Client – Server PDA Applications use Client – Server ModelModel

Page 6: Reliable Service Scheduler in a Distributed Web Service Environment

66

Server Server Side Side

ProcessinProcessingg

XML XML WriterWriter XML XML

ReaderReader

XML XML WriterWriterXML XML

ReaderReader

Client Side Server Client Side Server SideSide

Page 7: Reliable Service Scheduler in a Distributed Web Service Environment

77

Server Server Side Side

ProcessinProcessingg

XML XML WriterWriter XML XML

ReaderReader

XML XML WriterWriterXML XML

ReaderReader

Client Side Server Client Side Server SideSide

Page 8: Reliable Service Scheduler in a Distributed Web Service Environment

88

Server Server Side Side

ProcessinProcessingg

XML XML WriterWriter XML XML

ReaderReader

XML XML WriterWriterXML XML

ReaderReader

Client Side Server Client Side Server SideSide

Page 9: Reliable Service Scheduler in a Distributed Web Service Environment

99

Server Server Side Side

ProcessinProcessingg

XML XML WriterWriter XML XML

ReaderReader

XML XML WriterWriterXML XML

ReaderReader

Client Side Server Client Side Server SideSide

Page 10: Reliable Service Scheduler in a Distributed Web Service Environment

1010

Server Server Side Side

ProcessinProcessingg

XML XML WriterWriter XML XML

ReaderReader

XML XML WriterWriterXML XML

ReaderReader

Client Side Server Client Side Server SideSide

Page 11: Reliable Service Scheduler in a Distributed Web Service Environment

1111

Server Server Side Side

ProcessinProcessingg

XML XML WriterWriter XML XML

ReaderReader

XML XML WriterWriterXML XML

ReaderReader

Client Side Server Client Side Server SideSide

Page 12: Reliable Service Scheduler in a Distributed Web Service Environment

1212

Demo Time!Demo Time!

QB Rating Calculator Application QB Rating Calculator Application VS. VS.

primecomputing.com QB rating calculatorprimecomputing.com QB rating calculator--------------------------------------------------------------------------------------------------------------

Comparison of PDA Base Conversion Tool Comparison of PDA Base Conversion Tool Vs.Vs.

Windows Calculator ApplicationWindows Calculator Application

Page 13: Reliable Service Scheduler in a Distributed Web Service Environment

1313

Flagship ApplicationFlagship Application

Application Choice:Application Choice: Avatar Chat Environment-2DAvatar Chat Environment-2D Combines Game, Chat, UtilityCombines Game, Chat, Utility

Game: Interactive, FunGame: Interactive, Fun Chat: Real-time communicationChat: Real-time communication Utility: Navigate servicesUtility: Navigate services

Parallels previous team’s FlagshipParallels previous team’s Flagship

Page 14: Reliable Service Scheduler in a Distributed Web Service Environment

1414

Flagship ApplicationFlagship Application

Page 15: Reliable Service Scheduler in a Distributed Web Service Environment

1515

Flagship ApplicationFlagship Application

Page 16: Reliable Service Scheduler in a Distributed Web Service Environment

1616

Flagship ApplicationFlagship Application

FreeMovement

ScrolledMovement

Page 17: Reliable Service Scheduler in a Distributed Web Service Environment

1717

Flagship ApplicationFlagship ApplicationVisible Region

Page 18: Reliable Service Scheduler in a Distributed Web Service Environment

1818

Flagship ApplicationFlagship Application

textmap.push("##.#.#.#...#O#O#O..######.#.##");textmap.push("##.#.#.#...#O#O#O..######.#.##");textmap.push("##.###.#...O....#..#......#.##");textmap.push("##.###.#...O....#..#......#.##");textmap.push("##.#.#.#...#.,*.O..#.######.##");textmap.push("##.#.#.#...#.,*.O..#.######.##");textmap.push("##.........O.*,.#..#......#.##");textmap.push("##.........O.*,.#..#......#.##");textmap.push("##..###....#....O..######.#.##");textmap.push("##..###....#....O..######.#.##");textmap.push("##.#...#...O#..O#.........#.##");textmap.push("##.#...#...O#..O#.........#.##");textmap.push("##.#...#....O..#...########.##");textmap.push("##.#...#....O..#...########.##");

Page 19: Reliable Service Scheduler in a Distributed Web Service Environment

1919

Flagship ApplicationFlagship Application

Player

Client A

Client C

Client BServer

XML Doc:(Position)

Position X,YVelocity X,Y

XML Doc:(Message)

SenderText

Page 20: Reliable Service Scheduler in a Distributed Web Service Environment

2020

Flagship ApplicationFlagship Application

Work remaining:Work remaining: Port to PocketPCPort to PocketPC Share info with C# host (on same Share info with C# host (on same

system)system) Add functionalityAdd functionality

Page 21: Reliable Service Scheduler in a Distributed Web Service Environment

2121

Ethan TowneEthan Towne

Service Service Manager Manager

Overview and Overview and Important Important

Design Design DecisionsDecisions

Page 22: Reliable Service Scheduler in a Distributed Web Service Environment

2222

Service Manager DesignService Manager Design

To Client

To Client

Alters Agent Queue in Scheduler

Spawns Service Agent

Spawns Service Agent

Accepts Client Accepts Client ConnectionsConnectionsService

Manager

Agent 3

Agent 2

Page 23: Reliable Service Scheduler in a Distributed Web Service Environment

2323

Service AgentsService Agents

Each service has own thread called Each service has own thread called an “agent”an “agent”

Each agent only runs when their turn Each agent only runs when their turn has comehas come

Page 24: Reliable Service Scheduler in a Distributed Web Service Environment

2424

Design DecisionsDesign Decisions

Asynchronous vs. Synchronous data Asynchronous vs. Synchronous data reception.reception.

Using polymorphism to launch client Using polymorphism to launch client applicationsapplications

SQL queries used to pull data for SQL queries used to pull data for server implementationserver implementation

Data Transfer ProtocolData Transfer Protocol

Page 25: Reliable Service Scheduler in a Distributed Web Service Environment

2525

SynchronousSynchronous

Listening to a socket blocks the Listening to a socket blocks the thread until data arrives.thread until data arrives.

Page 26: Reliable Service Scheduler in a Distributed Web Service Environment

2626

AsynchronousAsynchronous

Listening to a socket creates a new Listening to a socket creates a new thread and blocks that thread.thread and blocks that thread.

Page 27: Reliable Service Scheduler in a Distributed Web Service Environment

2727

PolymorphismPolymorphism

Clients implement a common interface Clients implement a common interface (Base Class).(Base Class).

Server creates a pointer of type Server creates a pointer of type interface (Base Class).interface (Base Class).

Pointer can then dynamically be set to Pointer can then dynamically be set to point to the needed client application.point to the needed client application.

Page 28: Reliable Service Scheduler in a Distributed Web Service Environment

2828

Database BackendDatabase BackendtblUser

Fields:

Key: usrUD

Name

Pass

Info etc.

relServices

FK: usrID

FK: srvcID

tblServices

Fields:

Key: srvcID

Service Name

Usage

Info etc.

Page 29: Reliable Service Scheduler in a Distributed Web Service Environment

2929

SQL StatementsSQL Statements

Used to query database for unique data Used to query database for unique data sets. A simple query:sets. A simple query:

"Select * from testTable WHERE "Select * from testTable WHERE Name='"+name+ "' AND Pass='"+pass+"'"Name='"+name+ "' AND Pass='"+pass+"'"

Page 30: Reliable Service Scheduler in a Distributed Web Service Environment

3030

Relational StatementsRelational Statements

Used to select datasets from 2 or more Used to select datasets from 2 or more tables. For example:tables. For example:

““Select * FROM testTable, testTable2 Select * FROM testTable, testTable2 WHERE testTable.userId = 5 AND WHERE testTable.userId = 5 AND testTable.userID = testTable2.userID;testTable.userID = testTable2.userID;

Page 31: Reliable Service Scheduler in a Distributed Web Service Environment

3131

Data Transfer ProtocolData Transfer Protocol

XML used to transfer data.XML used to transfer data.

ToXML() and FromXML()ToXML() and FromXML()

Wraps/Unwraps data transferred into Wraps/Unwraps data transferred into packets containing important data packets containing important data for the server.for the server.

Page 32: Reliable Service Scheduler in a Distributed Web Service Environment

3232

Service Service SchedulerSchedulerDaniel RichardDaniel Richard

Page 33: Reliable Service Scheduler in a Distributed Web Service Environment

3333

AbstractAbstract

Service Scheduler DesignService Scheduler Design Handling InputHandling Input What needs to be completedWhat needs to be completed Final ProductFinal Product RecapRecap

Page 34: Reliable Service Scheduler in a Distributed Web Service Environment

3434

Scheduler

PriorityQueue

S1 S3 S2 S4

Soft Real-Time Queue

.NetRuntime

Dispatcher(service activator)

Page 35: Reliable Service Scheduler in a Distributed Web Service Environment

3535

Input Buffer QueueInput Buffer Queue

All Input is passed into an Input All Input is passed into an Input Buffer Queue.Buffer Queue.

The packets are scheduled according The packets are scheduled according to their priority or deadline.to their priority or deadline.

The service agent will be given The service agent will be given control of CPU when their packet is control of CPU when their packet is dispatched.dispatched.

Page 36: Reliable Service Scheduler in a Distributed Web Service Environment

3636

What’s Next?What’s Next? Implementation of the Service Implementation of the Service

SchedulerScheduler

Complete Implementation of the Complete Implementation of the Client-Server ModelClient-Server Model

Integration of Client and ServerIntegration of Client and Server

Page 37: Reliable Service Scheduler in a Distributed Web Service Environment

3737

Finished ProductFinished Product

Server executableServer executable Requires .Net FrameworkRequires .Net Framework

Client executableClient executable Runs on PDA or EmulatorRuns on PDA or Emulator

Fully Documented CodeFully Documented Code

Page 38: Reliable Service Scheduler in a Distributed Web Service Environment

3838

Future SemestersFuture Semesters

Expand on Database backendExpand on Database backend Add PC version of the Client programAdd PC version of the Client program Add more Client programs and Add more Client programs and

servicesservices Expand on Flagship ApplicationExpand on Flagship Application Possibilities are endlessPossibilities are endless

Page 39: Reliable Service Scheduler in a Distributed Web Service Environment

3939

RecapRecap

Demo of PDA ApplicationsDemo of PDA Applications Flagship ApplicationFlagship Application Service ManagerService Manager Service SchedulerService Scheduler Finished ProductFinished Product

Page 40: Reliable Service Scheduler in a Distributed Web Service Environment

4040

??