Chapter One: Distributed Information Systems
Chapter One: Distributed Information Systems
Chapter One
Web services are Extensible Markup Language (XML) applications mapped to programs, objects, or
databases or to comprehensive business functions. Using an XML document created in the form of a
message, a program sends a request to a Web service across the network, and, optional, receives a
reply, also in the form of an XML document.
Web services are a form of distributed information system, they are changing the way we think about
distributed software systems development. Many of the problems that Web services try to solve, as well as the
design constraints encountered along the way, can be understood by considering how distributed information
systems evolved in the past.
Web services can also be used for business-to-business (B2B) integration, connecting applications run by
various organizations in the same supply chain. Web services can also solve the broader problem of enterprise
application integration (EAI), connecting multiple applications from a single organization to multiple other
applications both inside and outside the firewall by presenting to the network a standard way of interfacing
with back-end software systems.
CORBA - common object request broker
architecture
The level of abstraction at which Web services operate encompasses such interaction styles as RPC (remote procedure
call) emulation, asynchronous messaging, one-way messaging, broadcast and publish/subscribe. Most major database
management systems, such as Oracle, SQL Server, and DB2, support XML parsing and transformation services,
allowing direct interaction between Web services and database management systems. Middleware vendors typically
also provide a mapping of Web services to their software systems, such as application servers and integration brokers.
To the user, therefore, interactions with Web services can appear as batch or online interactions, supporting
synchronous or asynchronous communications patterns, and as user interfaces written using Java programs, VB
(Visual Basic) programs, office applications, browsers, or thick clients to database management systems, to name a few,
and can map down to any type of underlying software system.
A client is any user or program that wants to perform an operation on the system.
The application logic determines what the system actually does. It takes care of enforcing the business
rules and establishing the business process. The application logic can take many forms: programs,
constraints, work flows, etc.
The resource manager deals with the organization (storage, indexing, and retrieval) of the data
necessary to support the application logic. This is typically a database but it can also be a text retrieval
system or any other data management system providing querying capabilities and persistence.
Each box represents a part of the system. Each arrow represents a connection between two parts of the
system.
Adding boxes makes the system modular: this provides opportunities for adding distribution and
parallelism. It also supports encapsulation, component–based design, reuse, etc. Adding arrows, on the
other hand, adds connections that need to be maintained; more coordination is necessary. The system
becomes more complex to monitor and manage.
The more boxes, the greater the number of context switches and intermediate steps to go through
before one gets to data. Performance suffers considerably. System designers try to balance the
flexibility of modular design with the performance demands of real applications.
One Tier
Two Tier (client/server)
Three Tier (middleware)
N-tier Architectures
Clusters and Tier Distribution
The presentation layer, application logic and resource manager are built as a monolithic entity.
Users/programs access the system through “dumb” terminals, whose display is controlled by the
information system.
As computers became more powerful, it was possible to move the presentation layer to
the client. This has several advantages:
Clients are independent of each other: one can have several presentation layers
depending on what each client needs to do.
One can take advantage of the computing power at the client machine to have more
sophisticated presentation layers while also saving computer resources on the server.
It introduces the concept of API (Application Program Interface). An interface to invoke
the system from the outside.
The resource manager only sees one client: the application logic. This greatly helps with
performance since there are no client connections/sessions to maintain.
Integrative Programming and Technologies - compiled by - Tsegaye A.
Client/server systems introduced the notion of service (the client invokes a service
implemented by the server)
Client/server systems also introduced the notion of service interface (how the client can
invoke a given service)
Taken together, the interfaces to all the services provided by a server define the server's
API
In a 3 tier system, the three layers are fully separated; they are also typically distributed
Middleware introduces an additional layer of business logic encompassing all underlying
systems
By doing this, a middleware system:
simplifies the design of clients by reducing the number of interfaces it needs to
know
provides transparent access to the underlying systems
acts as a platform for inter-system functionality and high level application logic
takes care of locating resources, accessing them, and gathering results
Integrative Programming and Technologies - compiled by - Tsegaye A.
Middleware systems also enable the integration of systems built using other architectures
N-tier architectures result from connecting several 3-tier systems to each other and/or by
adding an additional layer to allow clients to access the system via the Web
The Web layer was initially external to the information system (a true additional layer);
today, it is being incorporated into a presentation layer that resides on the server side
(part of the middleware infrastructure in a three tier system, or part of the server directly
in a two tier system)
The addition of the Web layer led to the notion of “application servers” which was used
to refer to middleware platforms supporting Web access
Integrative Programming and Technologies - compiled by - Tsegaye A.
Reading Assignment
Define and explain the following Software architectural Patterns/Styles and provide examples
for each
1.1.Web Technologies
Web services require several related XML-based technologies to transport and to transform data
into and out of programs and databases. Web services require the use of several related XML-
based technologies:
1.2.Web Services
Web services are open standard (XML, SOAP, HTTP, etc.) based web applications that interact
with other web applications for the purpose of exchanging data.
Different books and different organizations provide different definitions to Web Services. Some
of them are listed here.
A web service is any piece of software that makes itself available over the internet and
uses a standardized XML messaging system. XML is used to encode all communications
to a web service. For example, a client invokes a web service by sending an XML
message, then waits for a corresponding XML response. As all communication is in XML,
web services are not tied to any one operating system or programming language—Java
can talk with Perl; Windows applications can talk with Unix applications.
Web services are self-contained, modular, distributed, dynamic applications that can be
described, published, located, or invoked over the network to create products, processes,
and supply chains. These applications can be local, distributed, or web-based. Web
services are built on top of open standards such as TCP/IP, HTTP, Java, HTML, and
XML.
Web services are XML-based information exchange systems that use the Internet for
direct application-to-application interaction. These systems can include programs,
objects, messages, or documents.
A web service is a collection of open protocols and standards used for exchanging data
between applications or systems. Software applications written in various programming
languages and running on various platforms can use web services to exchange data over
Integrative Programming and Technologies - compiled by - Tsegaye A.
The basic web services platform is XML + HTTP. All the standard web services work using the
following components:
XML (Extensible Markup Language) - the basic foundation on which Web services are
built provides a language for defining data and how to process it. XML represents a
family of related specifications published and maintained by the World Wide Web
Consortium (W3C) and others.
A web service enables communication among various applications by using open standards such
as HTML, XML, WSDL, and SOAP. A web service takes the help of:
Integrative Programming and Technologies - compiled by - Tsegaye A.
You can build a Java-based web service on Solaris that is accessible from your Visual Basic
program that runs on Windows.
You can also use C# to build new web services on Windows that can be invoked from your web
application that is based on JavaServer Pages (JSP) and runs on Linux.
Example
Consider a simple account-management and order processing system. The accounting personnel
use a client application built with Visual Basic or JSP to create new accounts and enter new
customer orders.
The processing logic for this system is written in Java and resides on a Solaris machine, which
also interacts with a database to store information.
The client program bundles the account registration information into a SOAP message.
This SOAP message is sent to the web service as the body of an HTTP POST request.
The web service unpacks the SOAP request and converts it into a command that the
application can understand.
The application processes the information as required and responds with a new unique
account number for that customer.
Next, the web service packages the response into another SOAP message, which it sends
back to the client program in response to its HTTP request.
The client program unpacks the SOAP message to obtain the results of the account
registration process.
A web service is a unit of managed code that can be remotely invoked using HTTP. That is, it
can be activated using HTTP requests. Web services allow you to expose the functionality of
your existing code over the network. Once it is exposed on the network, other applications can
use the functionality of your program.
Interoperability
Web services allow various applications to talk to each other and share data and services among
themselves. Other applications can also use the web services. For example, a VB or .NET
application can talk to Java web services and vice versa. Web services are used to make the
application platform and technology independent.
Standardized Protocol
Web services use standardized industry standard protocol for the communication. All the four
layers (Service Transport, XML Messaging, Service Description, and Service Discovery layers)
use well-defined protocols in the web services protocol stack. This standardization of protocol
stack gives the business many advantages such as a wide range of choices, reduction in the cost
due to competition, and increase in the quality.
Low Cost Communication
Web services use SOAP over HTTP protocol, so you can use your existing low-cost internet for
implementing web services. This solution is much less costly compared to proprietary solutions
like EDI/B2B. Besides SOAP over HTTP, web services can also be implemented on other
reliable transport mechanisms like FTP.
CHARACTERISTICS
XML-Based
Integrative Programming and Technologies - compiled by - Tsegaye A.
Web services use XML at data representation and data transportation layers. Using XML
eliminates any networking, operating system, or platform binding. Web services based
applications are highly interoperable at their core level.
Loosely Coupled
A consumer of a web service is not tied to that web service directly. The web service interface
can change over time without compromising the client's ability to interact with the service. A
tightly coupled system implies that the client and server logic are closely tied to one another,
implying that if one interface changes, the other must be updated. Adopting a loosely coupled
architecture tends to make software systems more manageable and allows simpler integration
between different systems.
Coarse-Grained
Object-oriented technologies such as Java expose their services through individual methods. An
individual method is too fine an operation to provide any useful capability at a corporate level.
Building a Java program from scratch requires the creation of several fine-grained methods that
are then composed into a coarse-grained service that is consumed by either a client or another
service.
Businesses and the interfaces that they expose should be coarse-grained. Web services
technology provides a natural way of defining coarse-grained services that access the right
amount of business logic.
Synchronicity refers to the binding of the client to the execution of the service. In synchronous
invocations, the client blocks and waits for the service to complete its operation before
continuing. Asynchronous operations allow a client to invoke a service and then execute other
functions.
Asynchronous clients retrieve their result at a later point in time, while synchronous clients
receive their result when the service has completed. Asynchronous capability is a key factor in
enabling loosely coupled systems.
Integrative Programming and Technologies - compiled by - Tsegaye A.
Web services allow clients to invoke procedures, functions, and methods on remote objects using
an XML-based protocol. Remote procedures expose input and output parameters that a web
service must support.
Component development through Enterprise JavaBeans (EJBs) and .NET Components has
increasingly become a part of architectures and enterprise deployments over the past couple of
years. Both technologies are distributed and accessible through a variety of RPC mechanisms.
A web service supports RPC by providing services of its own, equivalent to those of a traditional
component, or by translating incoming invocations into an invocation of an EJB or a .NET
component.
One of the key advantages of XML is its generic way of representing not only data, but also
complex documents. These documents can be as simple as representing a current address, or
they can be as complex as representing an entire book or Request for Quotation (RFQ). Web
services support the transparent exchange of documents to facilitate business integration.
The first is to examine the individual roles of each web service actor.
The second is to examine the emerging web service protocol stack.
There are three major roles within the web service architecture:
Service Provider
Integrative Programming and Technologies - compiled by - Tsegaye A.
This is the provider of the web service. The service provider implements the service and makes it
available on the Internet.
Service Requestor
This is any consumer of the web service. The requestor utilizes an existing web service by
opening a network connection and sending an XML request.
Service Registry
This is a logically centralized directory of services. The registry provides a central place where
developers can publish new services or find existing ones. It therefore serves as a centralized
clearing house for companies and their services.
A second option for viewing the web service architecture is to examine the emerging web service
protocol stack. The stack is still evolving, but currently has four main layers.
Service Transport
This layer is responsible for transporting messages between applications. Currently, this layer
includes Hyper Text Transport Protocol (HTTP), Simple Mail Transfer Protocol (SMTP), File
Transfer Protocol (FTP), and newer protocols such as Blocks Extensible Exchange Protocol
(BEEP).
XML Messaging
This layer is responsible for encoding messages in a common XML format so that messages can
be understood at either end. Currently, this layer includes XML-RPC and SOAP.
Service Description
This layer is responsible for describing the public interface to a specific web service. Currently,
service description is handled via the Web Service Description Language (WSDL).
Service Discovery
Integrative Programming and Technologies - compiled by - Tsegaye A.
This layer is responsible for centralizing services into a common registry and providing easy
publish/find functionality. Currently, service discovery is handled via Universal Description,
Discovery, and Integration (UDDI).
As web services evolve, additional layers may be added and additional technologies may be
added to each layer.
Over the past few years, three primary technologies have emerged as worldwide standards that make up
the core of today's web services technology. These technologies are discussed below.
XML-RPC
This is the simplest XML-based protocol for exchanging information between computers.
SOAP
WSDL
WSDL is an XML-based language for describing web services and how to access them.
WSDL definition describes how to access a web service and what operations it will
perform.
WSDL is a language for describing how to interface with XML-based services.
WSDL is an integral part of UDDI, an XML-based worldwide business registry.
WSDL is the language that UDDI uses.
WSDL is pronounced as 'wiz-dull' and spelled out as 'W-S-D-L'
UDDI
UDDI is an XML-based standard for describing, publishing, and finding web services.