Title: A Runtime System for Interactive Web Services
1A Runtime System forInteractive Web Services
- Claus Brabrand, Anders Møller,
- Anders Sandholm, Michael I. Schwartzbach
BRICS, University of Aarhus, Denmark
2Plan
- Illustrate problems with CGI
- example interactive web service.
- Solve problems one by one
- building on top of CGI.
- Additional problems and solutions.
- Package solutions into runtime system.
- Conclusion.
3An Interactive Web Service
4Problem Save, Restore State
ltINPUT TYPEhidden NAMEconfirmed VALUE1gt
ltINPUT TYPEhidden NAMEfname VALUEClausgt
ltINPUT TYPEhidden NAMEfee VALUE495gt
5Problem Bookmarks
6Problem Bookmarks
Bookmark What?
7Problem Back Button
8Problem Back Button
9Problem Back Button
Pay twice ?!
10CGI Problems
- Save, Restore State
- Bookmark
- Back Button
11CGI Problems
- Save, Restore State
- Bookmark
- Back Button
12Components
client
CGI
HTML
Internet
HTTP server
HTML
CGI
restore compute save
program
database
13Adding a Connector
client
CGI
HTML
Internet
HTTP server
CGI
HTML
connector
redirect
HTML
CGI
restore compute save
program
database
14CGI Problems
- Save, Restore State
- Bookmark
- Back Button
15CGI Problems
- Save, Restore State Connector
- Bookmark
- Back Button
16CGI Problems
- Save, Restore State Connector
- Bookmark
- Back Button
17Problem Bookmarks
- Problem
- CGI URL bookmarked (not HTML response).
- Consequence
- Must complete entire service right away.
- Would like
- Pause service (bookmark), resume later.
18Components
client
CGI
HTML
Internet
HTTP server
CGI
HTML
connector
HTML
CGI
program
database
19Adding an HTML Reply File
client
CGI
jump
Internet
HTTP server
CGI
jump
connector
done!
CGI
HTML reply file
program
HTML
database
20CGI Problems
- Save, Restore State Connector
- Bookmark
- Back Button
21CGI Problems
- Save, Restore State Connector
- Bookmark Reply File
- Back Button
22CGI Problems
- Save, Restore State Connector
- Bookmark Reply File
- Back Button
23Problem Back Button
- Problem History of old requests
- Annoying.
- No longer make sense.
- Dangerous! (for client and server)
- Would like
- Back should take us back.
- Never see old CGI requests.
24Components
client
CGI
jump
Internet
HTTP server
CGI
jump
connector
done!
CGI
HTML reply file
program
HTML
database
25Components
client
CGI
jump
Internet
HTTP server
CGI
jump
connector
same URL
done!
CGI
HTML reply file
program
HTML
database
26CGI Problems
- Save, Restore State Connector
- Bookmark Reply File
- Back Button
27CGI Problems
- Save, Restore State Connector
- Bookmark Reply File
- Back Button Reply File
28Additional Problems
29Additional Problems
30What is going on?
- Error? Abort...
- Package Lost?
- Service Crash?
- Connection?
- Ok? or Wait !?
- Searching Database?
- Long Computation?
- Waiting for a Resource?
31Problem User Impatience
- Consequence
- Users leave service.
- Would like
- Explain delays.
- Searching database Please wait..
32Components
client
CGI
jump
Internet
HTTP server
CGI
jump
connector
done!
CGI
HTML reply file
program
HTML
database
33Adding a Connector Timeout
client
CGI
jump
Internet
HTTP server
CGI
jump
connector
Timeout
done
CGI
HTML reply file
program
update
database
34CGI Problems
- Save, Restore State Connector
- Bookmark Reply File
- Back Button Reply File
- User Impatience
35CGI Problems
- Save, Restore State Connector
- Bookmark Reply File
- Back Button Reply File
- User Impatience Timeout
36CGI Problems
- Save, Restore State Connector
- Bookmark Reply File
- Back Button Reply File
- User Impatience Timeout
- Concurrency Control
37Concurrency Control
- Problem Parallel service processes.
- Access shared resources.
- Require synchronization.
- Solution
- Allow separate specification of constraints.
- Use safety controller process
- Ensures that service obeys constraints.
38Components
client
CGI
jump
Internet
HTTP server
CGI
jump
connector
Timeout
done
CGI
HTML reply file
program
update
database
39Adding a Safety Controller
client
CGI
jump
Internet
HTTP server
CGI
jump
connector
Timeout
done
CGI
wait
HTML reply file
program
controller
update
pass
database
40CGI Problems
- Save, Restore State Connector
- Bookmark Reply File
- Back Button Reply File
- User Impatience Timeout
- Concurrency Control
41CGI Problems
- Save, Restore State Connector
- Bookmark Reply File
- Back Button Reply File
- User Impatience Timeout
- Concurrency Control Controller
42Runtime System
- Everything implemented!
- in C for Unix / Linux.
- Available http//www.brics.dk/bigwig/runwig/
- Source
- Documentation.
- Examples.
43ltbigwiggt
- Research project at BRICS.
- Domain specific high-level language
- Rapid construction of interactive web services.
- Compiles into
- HTML, CGI, Java, JavaScript,
- Uses our runtime system extensively.
http//www.brics.dk/bigwig/
44ltbigwiggt
- Research project at BRICS.
- Domain specific high-level language
- Rapid construction of interactive web services.
- Compiles into
- HTML, CGI, Java, JavaScript,
- Uses our runtime system extensively.
Released June 1999
http//www.brics.dk/bigwig/
45Conclusion
- CGI widely used, but inherently low-level.
- Our Runtime System
- Higher level.
- Built on top of CGI.
- Compact and efficient.
- Solves the problems discussed.
46The CGI Model
Client
Server
read fill-out submit
CGI
restore compute save
HTML
read fill-out submit
CGI
restore compute save
HTML
47Adding a Connector
Client
Server
read fill-out submit
CGI
awake compute sleep
HTML
read fill-out submit
CGI
awake compute sleep
HTML