1. ITE 3108 – Internet Programming
and Web Services
1. Overview of Distributed Systems
Daminda Herath
B.Sc(Col), MBCS, M.Sc(Col), MCSSL, MIEEE
2. Distributed Systems
A Distributed System is a collection of individual computing devices that can
communicate with each other (i.e. a collection of independent computers,
interconnected via a network, capable of collaborating on a task).
This general definition encompasses a wide range of modern day computer systems,
ranging from a VLSI chip to a tightly coupled shared memory microprocessor, to a
local area cluster of workstations, to the internet.
Distributed Systems are ubiquitous today throughout business, academia,
government and the home. Typically they provide means to share resources, for
instance, special purpose equipment and to share data, crucial for our information
based economy.
3. Ubiquitous computing (ubicomp)
Ubiquitous computing (ubicomp) is an advanced computing
concept where computing is made to appear everywhere and
anywhere. In contrast to desktop computing, ubiquitous computing
can occur using any device, in any location, and in any format. A
user interacts with the computer, which can exist in many different
forms, including laptop computers, tablets, terminals and phones.
4. A Distributed System is a collection of independent computers that
appears to its users as a Single coherent System.
9. Centralized vs. Distributed Computing
The terms centralized and distributed computing is used to describe
where the network processing takes place. In a centralized
computing model, one system provides both the data storage and
the processing power for client systems. This networking model is
most often associated with computer mainframes and dumb
terminals, where no processing or storage capability exists at the
workstation. These network environments are rare, but they do still
exist.
A distributed network model has the processing power distributed
between the client systems and the server. Most modern networks
use the distributed network model, where client workstations share
in the processing responsibilities.
10.
11.
12. Distributed System Paradigms
Message Passing
Message passing is the most fundamental paradigm for distributed
applications.
•A process sends a message representing a request.
•The message is delivered to a receiver, which processes the
request, and sends a message in response.
•In turn, the reply may trigger a further request, which leads to a
subsequent reply, and so forth.
14. Client Server Paradigm
•The Client-Server paradigm is the most prevalent model for
distributed computing protocols.
•It is the basis of all distributed computing paradigms at a higher
level of abstraction.
•It is service-oriented, and employs a request-response protocol.
•Operations required include those for a server process to listen and
to accept requests, and for a client process to issue requests and
accept responses.
•By assigning asymmetric roles to the two sides, event
synchronization is simplified: the server process waits for requests,
and the client in turn waits for responses.
15.
16. On the Internet, many services are Client-server applications.
These services are often known by the protocol that the application
implements. Well known Internet services include HTTP, FTP, DNS,
etc.
User applications may also be built using the client-server
paradigm.
17. Peer to Peer Paradigm
•Peer-to-peer is an architecture where computer resources and
services are direct exchanged between computer systems.
•These resources and services include the exchange of information,
processing cycles, cache storage, and disk storage for files.
•In such architecture, computers that have traditionally been used
solely as clients communicate directly among themselves and can
act as both clients and a servers, assuming whatever role is most
efficient for the network.
•In the peer-to-peer paradigm, the participating processes play
equal roles, with equivalent capabilities and responsibilities (hence
the term “peer”). Each participant may issue a request to another
participant and receive a response.
18.
19. The Message System Paradigm
•The Message System or Message-Oriented Middleware (MOM)
paradigm is an elaboration of the basic message-passing paradigm.
•In this paradigm, a message system serves as an intermediary
among separate, independent processes.
•The message system acts as a switch for messages, through
which processes exchange messages asynchronously, in a
decoupled manner.
•A sender deposits a message with the message system, which
forwards it to a message queue associated with each receiver.
Once a message is sent, the sender is free to move on to other
tasks.
20. The Message System Paradigm
Two subtypes of message system models exist
The Point-To-Point Message Model
The Publish/Subscribe Message Model
21. The Point-To-Point Message Model
• In this model, a message system forwards a message from the
sender to the receiver’s message queue. Unlike the basic
message passing model, the middleware provides a message
depository, and allows the sending and the receiving to be
decoupled. Via the middleware, a sender deposits a message in
the message queue of the receiving process. A receiving
process extracts the messages from its message queue, and
handles each one accordingly.
• Compared to the basic message-passing model, this paradigm
provides the additional abstraction for asynchronous operations.
To achieve the same effect with basic message-passing, a
developer will have to make use of threads or child processes.
22. The Publish/Subscribe Message Model
•In this model, each message is associated with a specific topic or
event. Applications interested in the occurrence of a specific event
may subscribe to messages for that event. When the awaited event
occurs, the process publishes a message announcing the event or
topic. The middleware message system distributes the message to
all its subscribers.
•The publish/subscribe message model offers a powerful
abstraction for multicasting or group communication. The publish
operation allows a process to multicast to a group of processes, and
the subscribe operation allows a process to listen for such multicast.
23. The Publish/Subscribe Message Model
•In the publish/subscribe domain, message producers are
called publishers and message consumers are
called subscribers. They exchange messages by means of a
destination called a topic: publishers produce messages to a topic;
subscribers subscribe to a topic and consume messages from a
topic
25. Remote Procedure Call (RPC)
•As applications grew increasingly complex, it became desirable to
have a paradigm which allows distributed software to be
programmed in a manner similar to conventional applications which
run on a single processor.
•The Remote Procedure Call (RPC) model provides such an
abstraction. Using this model, inter-process communications
proceed as procedure, or function, calls, which are familiar to
application programmers.
• A remote procedure call involves two independent processes,
which may reside on separate machines. A process, A, wishing to
make a request to another process, B, issues a procedure call to B,
passing with the call a list of argument values. As in the case of
local procedure calls, a remote procedure call triggers a predefined
action in a procedure provided by process B. At the completion of
the procedure, process B returns a value to process A.
26.
27. Collaborative Applications
In this model, processes participate in a collaborative session as a
group. Each participating process may contribute input to part or the
entire group.
Processes may do so using:
•Multicasting to send data to all or part of the group, or
•They may use a Virtual sketchpads or whiteboards which allows
each participant to read and write data to a shared display.
29. Mobile Agents
•An agent is “an independent software program which runs on
behalf of a network user”.
•A mobile agent is a program which, once it is launched by a user,
can travel from node to node autonomously, and can continue to
function even if the user is disconnected from the network.
•In this model, an agent is launched from an originating host.
•The agent travels from host to host according to an itinerary that it
carries.
•At each stop, the agent accesses the necessary resources or
services, and performs the necessary tasks to accomplish its
mission.
30.
31. •An agent server process runs on each participating host.
•Participating hosts are networked through links that can be low-
bandwidth and unreliable.
•An agent is a serializable object whose execution state can be
frozen for transportation and reconstituted upon arrival at a remote
site
•The paradigm offers the abstraction for a transportable program or
object.
•In lieu of message exchanges, data is carried by the
program/object as the program is transported among the
participants.
32. Advantages of Mobile Agents:
•They allow efficient and economical use of communication
channels which may have low bandwidth, high latency, and may be
error-prone.
•They enable the use of portable, low-cost, personal
communications devices to perform complex tasks even when the
device is disconnected from the network.
•They allow asynchronous operations and true decentralization