Professional Documents
Culture Documents
Web Technologies
© Copyright 2011 Srdjan Komazec 1
Where are we?
# Title
1 Distributed Information Systems
2 Middleware
3 Web Technologies
4 Web Services
5 Basic Web Service Technologies
6 Web 2.0 Services
7 Web Service Security
2
Outline
• Motivation
• Technical solution
– Exchanging Information over the Internet
– Web Technologies for Supporting Remote Clients
– Application Servers
– Web Technologies for Application Integration
• Possible extensions
• Summary
• Resources
3
Motivation
4
Motivation
• This lesson aims at introducing basic Web technologies that are used to
implement “Web” portion of Web services.
5
Technical Solution
Exchanging Information over the Internet
6
Exchanging Information over the Internet
Brief history
• The same team came up with the name World Wide Web
– The idea is today promoted and governed by WWW Consortium (W3C).
8
Exchanging Information over the Internet
Hyper Text Transfer Protocol (HTTP)
• URLs are the dominant way to identify documents over the Web.
– In addition to identifying a resource, a URL provides a means to locate it
• A URL defines the name of the protocol (i.e., scheme) which should be
used to access the document, the address of the machine where the
resource is located, and hierarchical description of the resource location
(and more like query string, and anchor).
9
Exchanging Information over the Internet
Hyper Text Transfer Protocol (HTTP)
10
Exchanging Information over the Internet
Hyper Text Transfer Protocol (HTTP) - Example
11
Exchanging Information over the Internet
Hyper Text Transfer Protocol – Intermediary systems
12
Exchanging Information over the Internet
Hyper Text Transfer Protocol – Intermediary systems
HTTP tunnel
firewall
HTTP HTTP HTTP HTTP
client proxy gateway server
13
Exchanging Information over the Internet
Hyper Text Transfer Protocol – Limitations
• No data encryption
– Secure Socket Layer (SSL) developed by Netscape (1996), and its successor
Transport Layer Security (TLS).
• Relies on public key encryption to protect data transferred over TCP/IP.
– Hyper Text Transfer Protocol over TLS/SSL (HTTPS)
• Allows Web server and client to use TLS/SSL to authenticate to each other and establish an
encrypted connection between themselves.
• Protocol is stateless
– Information is not shared across HTTP request/response roundtrips.
– Application developer is responsible for maintaining the relationships (i.e., state).
– HTTP Cookies developed by Netscape (1994).
• Enabling deployment of small data structures on the client machine on behalf of Web server.
• They can maintain state information, can be used for personalization, tracking, session
management.
14
Technical Solution
Web Technologies for Supporting Remote Clients
15
Web Technologies for Supporting Remote Clients
An Example
• Information systems today are opening for some other users (e.g.
customers)
– Usage of Automatic Teller Machines (ATMs) by banks gives customers easier access
to their accounts.
– Manual work when dealing with customers disappears which reduces costs for banks.
• ATMs are not in a personal possession and they still incur some costs
for customers (they need to travel to use the provided services)
– Once the customer owns its personal ATMs (i.e. client) possibilities are endless –
advanced applications, no usage constrains, etc.
16
Web Technologies for Supporting Remote Clients
Extension of 3-tier architecture
client
middleware
server
(resource manager)
17
Web Technologies for Supporting Remote Clients
Java Applets
18
Web Technologies for Supporting Remote Clients
Java Applets
server
(resource manager)
19
Web Technologies for Supporting Remote Clients
Common Gateway Interface (CGI)
20
Web Technologies for Supporting Remote Clients
Common Gateway Interface (CGI)
HTTP GET
request
firewall
Web
browser
client
CGI program
middleware
server
(resource manager)
Copyright Springer Verlag Berlin Heidelberg 2004
21
Web Technologies for Supporting Remote Clients
Java Servlets
• Java servlets use exactly the same idea as CGI scripts but
– Servlets are running as threads of a Java server process.
– They run as a part of the Web server.
– They are invoked directly by embedding servlet-specific information within an HTTP
request.
– This minimizes overhead, reduces memory requirements, and enables persistent
context management in contrast to CGI scripts.
• Session tracking, sharing of DB connections, caching as optimization technique.
22
Web Technologies for Supporting Remote Clients
Java Servlets
Web server
firewall
client
middleware
server
(resource manager)
Copyright Springer Verlag Berlin Heidelberg 2004
23
Technical Solution
Application Servers
24
Application Servers
Introduction
25
Application Servers
Introduction
other protocols
client
firewall
presentation layer
26
Application Servers
Support for the Application Logic
27
Application Servers
Support for the Application Logic – J2EE AS architecture
presentation layer
administration
EJB container
services
Copyright Springer Verlag Berlin Heidelberg 2004
JNDI
JMS
28
Application Servers
Support for the Application Logic
29
Application Servers
Support for the Presentation Layer
30
Application Servers
Support for the Presentation Layer
client
servers for other
E-mail server Web server
connections (e.g., WAP)
administration
caching,…)
security)
services
pooling,
personalization logic
presentation layer
31
Application Servers
Support for the Presentation Layer – Support for clients
• Web browsers
– The dynamic components which generate HTML are integrated with the application
logic layer.
– JSP fragments can be easily linked with EJBs through EJB containers.
– Applets may interact with app server through RMI and CORBA/IIOP.
• Devices
– Smaller devices may use XHTML Mobile Profile.
– Dynamic generation of content in different markup languages and automatic
conversion between these languages is also needed.
– Devices may be peculiar and this may impose some problems in terms of information
organization, etc. It may require different presentation (and even application) logic to
be written.
• Email-programs
– App server may support packaging of information which is delivered through SMTP.
• Web service clients
– Require support for SOAP.
33
Web Technologies for Application Integration
Architectures for WAN integration
• Before the pervasive Web only two of the strategies were realistic:
– specialized clients at the level of message exchanges, and
– direct integration of middleware layers (if they are compatible).
34
Web Technologies for Application Integration
Architectures for WAN integration
client client
middleware middleware
server server
(resource manager) (resource manager)
35
Web Technologies for Application Integration
Middleware Extensions
• The solution is to trick the firewall into believing that traffic is actually
allowed
– Tunneling stands for packaging the hidden protocol into the allowed one.
– It is common to enable tunneling through HTTP or SSH.
– Intermediary must be used to convert original message into HTML or XML, send
document using HTTP, extract the message from one document once it reaches the
recipient.
– Resulting architecture is rather cumbersome as it requires yet additional layer and
introduces another level of indirection.
37
Web Technologies for Application Integration
Firewalls and tunneling through HTTP
HTTP tunnel
firewall
firewall
Web Web
server server
middleware middleware
remote-middleware remote-middleware
protocol protocol
WAN communication WAN communication
protocol protocol
server server
(resource manager) Copyright Springer Verlag Berlin Heidelberg 2004 (resource manager)
38
Web Technologies for Application Integration
Common Data Representation: EDIFACT
39
Web Technologies for Application Integration
Common Data Representation: XML
40
Possible Extensions
41
Possible Extensions
42
Summary
43
Summary
44
References
45
References
• Mandatory reading
– Gustavo Alonso, Fabio Casati, Harumi Kuno, and Vijay Machiraju. Web Services -
Concepts, Architectures and Applications. Springer-Verlag, 2004. 4th chapter
46
References
47
Next Lecture
# Title
1 Distributed Information Systems
2 Middleware
3 Web Technologies
4 Web Services
5 Basic Web Service Technologies
6 Web Service Composition
7 Web 2.0 Services
8 Web Service Security
48
Questions?
49