Powerpoint 97
Download
Report
Transcript Powerpoint 97
LYU9901-Travel Net
Supervisor: Prof. Michael R. Lyu
Students: Ho Chi Ho Malcolm
Lau Chi Ho Arthur
(Presentation on 29-02-2000)
Outline
•
•
•
•
Progress on first term
Progress on second term
Current Progress
Future Plans
Work Done in 1st Term
• Set up an online web application TravelNet on a NT web server
• Implement different functions of TravelNet
using Java Servlet and HTML
Flight Search
• Search Flights on preferences of users
• Type of Search: One-way
• Principle: Call Airline Manager of each
airline to query and access its own database
for information on flights
Travel Shop
• Selling of travel related accessories such as
luggage, map, guide book, etc
• Principle: A shop basket system which
records items bought and initiates the
payment system when checkout.
Travel Guides
• Providing textual information on Cities
covered by TravelNet
• Principle: pure HTML pages
Membership
• Require users to register first before using
our services for better management and
promotion
• Allow the change of personal information
after login
• Principle: Maintain an user account
database and login verification system
Security
• Necessary for user login and payment
• Consideration: Convenience and
compatibility in browser environment
• Use of SSL between browser and web
server
Work done in this term
• Payment Gateway
• Enhancement of Online shop
• Enhancement of Flight Search
Payment Gateway for TravelNet
• To be a more realistic system
• Simulate payment in a secure way
• In this part:
– Description of communication between
merchant and Payment Gateway (PG)
– Performance measure of a payment transaction
Communication method
Merchant
(TravelNet)
•
•
•
•
•
•
Payment
Gateway (PG)
Asymmetric key encryption on a TCP connection.
Receiver use it’s own private key to decrypt message.
Sender use receiver’s public key to encrypt message.
Keys with 512 bit-length
Hard to decrypt for hackers even with public key
Merchant fill in client object and issue a start operation
Performance: Threaded Model
Process Tim e (m s)
Average Total CheckOut Time
Average Time spent on PG
20000
17500
15000
12500
10000
7500
5000
2500
0
1
2
3
4
5
6
7
8
9
Num ber of concurrent users
10
Performance: Non-Threaded Model
Process Tim e (m s)
Average Total CheckOut Time
Average Time Spent on PG
20000
17500
15000
12500
10000
7500
5000
2500
0
1
2
3
4
5
6
7
8
9
Num ber of concurrent users
10
Enhancement of Online Shop
• Dynamic generation of shopping item pages
• Allow easy maintenance
Enhancement of Flight Search
• Implementation of Round-Trip Search
• Display of search result
– shown more complete information
– sort result by time
Current Progress
• Implementing Itinerary Management
System
• Investigating CORBA Integration
• Investigating JSP
Itinerary Management
• Maintain Users’ Flight Itinerary
• Allow users to reserve flights eventually
• Basic Functions:
–
–
–
–
View items
Add items
Delete items
Reserve items to Airline
Itinerary Management(2)
• Will be finished soon so as to finalize the
system for CORBA integration
CORBA Integration
• CORBA - general standard on developing
distributed programs
• Refer to CSC5110 for details!
CORBA Integration(2)
• Why CORBA in TravelNet?
• Existence of distributed component:
– e.g. Airlines’ Databases on Flights
• Current Approach: Airline Manager resides
on TravelNet to be called, which lacks
parallelism & increase the load
CORBA Integration(3)
• CORBA Approach: Airline Manager resides
on each airline server, to increase
parallelism and decrease TravelNet’s server
load
• More benefits: the use of Object Activation
Daemon(OAD) for better resources
allocation
CORBA Integration(4)
• Challenge:
– the integration of CORBA is not simple
– CORBA is commonly used in Applets and
Application but not Servlet
• Tools:
– Visibroker for Java
Introduction to JSP
• Today’s Web sites want to display dynamic
content based on user and session.
• Mixing the "static" content of HTML files with
"directives" for accessing or generating dynamic
content.
• Java Server Pages provide server-side scripting
support for generating web pages with combined
static and dynamic content.
Displaying dynamic content
• Common Gateway Interface (CGI)
• Active Server Pages (ASP)
• Java Servlets & Java Server Page (JSP)
JSP features
• Combines the worlds of HTML and Java Servlet
programming
• Similar to HTML pages with new tags to control the
generation of dynamic content
• Pre-compilation of JSP to Servlet which is responsible
for generating dynamic pages
• Reside in application server memory (pre-load OR 1st
access)
Why use JSP?
• Platform independent
• Fast Response
• Reusability nature with Java classes or
Java Beans
JSP
Content
• Standard HTML + Tags for scripting in the Java language.
• Tags like:
– <jsp:useBean> :Locates or instantiates a Beam with a
specific name and scope
– <% code fragment %>: Contains a code fragment valid
in page scripting language
– <%= expression %>: return expression value to output
stream (client browser).
• JSP will finally be compiled to Servlets to access Beans
Compilation of JSP
• .jsp file will be compiled to be a Servlet
• Auto compile on
– the first request of a .jsp file
– the first request after changes on a .jsp file
• No compilation is needed if there is no update
– Generate output (HTML) by Servlet in memory
– Can be pre-loaded
•Request from browser to JSP of HTTP server
•Servlet request the Bean
•Bean request information from back-ends
•JSP response requested information to browser
Simple Example
Time.jsp
<HTML><H1>TIME JSP</H1>
<%
java.util.Date dt =
new java.util.Date(System.currentTimeMillis() );
%>
<%=dt.getHours()%>
: <%=dt.getMinutes()%>
: <%=dt.getSeconds()%>
</HTML>
Request = http://host/Time.jsp
Output on Client Browser
TIME JSP
18:35:20
Future Plans
•
•
•
•
Finalize the existing system
Integration of CORBA
Enhancement to the system, e.g JSP
Other possible features depends on time
~ END ~