Cis017 6 revision-2015_distributed

23
Revision Distributed Architectures

Transcript of Cis017 6 revision-2015_distributed

Page 1: Cis017 6 revision-2015_distributed

Revision

Distributed Architectures

Page 2: Cis017 6 revision-2015_distributed

4 Goals of a Distributed System• Accessibility

– Making resources (files, printers, storage) accessible for the user

• Transparency– Reasonably hiding the fact that resources are distributed across a

network– Forms of transparency

• Openness– Keeping the system “open” – building a system that offers services

according to standard rules that describe the syntax and semantics of those services

• Scalability– Being able to adapt to different requirements in terms of size, location and

organisation– Types of scalability

2CIS017-6 Distributed and Parallel Architecture

Page 3: Cis017 6 revision-2015_distributed

Performance Measures of the Design of a Distributed System

• Scalability– already covered

• Maintainability– ease of modification to correct faults or improve performance

• Extensibility– ease of adding new components to the system

• Availability– probability of the system operating correctly at any given moment

• Reliability– time between failures

• Security– protection against disclosure, alteration, or denial of service

• Fault tolerance– ability to provide a service when errors occur

3CIS017-6 Distributed and Parallel Architecture

Page 4: Cis017 6 revision-2015_distributed

TransparencyTransparency

• A distributed system should hide its distributed nature from its users

• Appearing and functioning as a normal centralized system

• One of the reasons why we want transparency in distributed systems

Page 5: Cis017 6 revision-2015_distributed

Forms of Transparency

Dropbox Web resourcesEmailTry to find examples of 3-4 different types of transparency!

• Access Transparency• Location transparency • Concurrency transparency• Replication transparency

• Failure Transparency• Mobility Transparency• Performance transparency • Scaling transparency

Page 6: Cis017 6 revision-2015_distributed

Distributed Computing Systems• We can make a deferent distinction between three

subtypes of distributed computing:

– Cluster Computing

– Grid Computing

– Cloud Computing

– Warehouse-scale computers– Co-operative distributed computing projects– Sensor networks

6CIS017-6 Distributed and Parallel Architecture

Page 7: Cis017 6 revision-2015_distributed

Communicating Entities• Nodes

– For example, sensors• Processes

– Virtual processors each with their own address space, synchronization and communication resources, files, ...

• Threads– Activities (threads of execution) sharing an execution

environment with other threads– Can be executed concurrently

• Objects– Sets of data and methods– Communicate with other objects by invoking their methods– Methods are defined as an interface

CIS017-6 Distributed and Parallel Architecture

Page 8: Cis017 6 revision-2015_distributed

Middleware• Middleware is a software layer providing a programming abstraction• Masks differences of networks, hardware, operating systems, programming

languages (transparency)• Can hide the fact that messages are passed over a network for invocation

request and reply• Lives in the application layer; provides session functionality• General purpose and application independent protocols• Tasks: Resource management and scheduling; Information registration and

discovery; Authentication; Security; Storage access; Communication• Examples:

– Common Object Request Broker (CORBA)– Java RMI– The Globus Toolkit– Authenticaton and authorisation

• Limitations? Role in a distributed or GRID system?

Page 9: Cis017 6 revision-2015_distributed

System Architectures• Mainframes• Client-server systems

– 2-tier– 3-tier

• Horizontal distribution– Distributed databases– Peer-to-peer systems– Content delivery networks

CIS017-6 Distributed and Parallel Architecture

Page 10: Cis017 6 revision-2015_distributed

Communication Paradigms for Distributed Applications

• Fundamental paradigm– Message passing

• Remote invocation paradigm– RPC– RMI

• Indirect communication– Message queue paradigm– Publish-Subscribe paradigm– Publish-Find-Bind– Web services paradigm– MapReduce paradigm

CIS017-6 Distributed and Parallel Architecture

S ervic esP rovider

S ervic esReques ter

S ervic esBroker F ind

W e b S e rv ice s

Page 11: Cis017 6 revision-2015_distributed

Persistent vs. Transient Communication

• Persistent communication– Message stored by the communication middleware as long as it takes

to deliver it– Sending application does not need to continue execution after submitting

the message (allows for asynchronous communication)– Receiving application need not be executing when the message is

submitted– Example: email systems

• Transient communication– Message is stored by the communication system only as long as the

sending and receiving applications are executing.– If the middleware cannot deliver a message due to a transmission

interrupt, or because the recipient is currently not active, the message will simply be discarded

– Example: transport-level communication services (being built upon traditional store-and-forward routers – if the router can’t deliver, it drops the message)

CIS017-6 Distributed and Parallel Architecture

Page 12: Cis017 6 revision-2015_distributed

Asynchronous vs. Synchronous Communication

• Asynchronous communication– Sender continues immediately after it has submitted its

message– Message is (temporarily) stored immediately by the

middleware upon submission

• Synchronous communication– Sender is blocked until its request is known to be accepted

CIS017-6 Distributed and Parallel Architecture

Page 13: Cis017 6 revision-2015_distributed

Discrete vs. Streaming Communication

• Discrete– All communicating parties communicate by messages

• Each message forms a complete unit of information

• Streaming– Messages are related to each other

• By the order they are sent• By their temporal relationship

CIS017-6 Distributed and Parallel Architecture

Page 14: Cis017 6 revision-2015_distributed

Distributed Computing

• Remote Procedure Call (RPC)– Synchronous or asynchronous– Implementation with client and server stubs

• Message-Queuing Model– Persistent or transient communication– Publish-Subscribe paradigm

• Stream-Oriented Communication– Quality of Service (QoS)

Page 15: Cis017 6 revision-2015_distributed

Distributed Computing

• Remote Method Invocation (RMI)– Similar to RPC - but for objects

• Web Services– Publish-Find-Bind paradigm– Protocols (HTTP, XML, JSON, SOAP, WSDL, UDDI)

Page 16: Cis017 6 revision-2015_distributed

3 Models for CommunicationThree widely used models for communication:

• Remote Procedure Call (RPC)– Hide most of the intricacies of message passing – Ideal for client/server applications

• Message-Oriented Middleware (MOM)– High-level message queuing model, similar to email– Communication does not follow the rather strict pattern of client/server

interaction.

• Data Streaming– Used in multimedia distributed systems– Provides support for communication of continuous media, such as audio

and video– Stream: continuous flow of messages – Subject to various timing constraints

CIS017-6 Distributed and Parallel Architecture

Page 17: Cis017 6 revision-2015_distributed

Streams and Quality of Service

• Timing requirements are generally expressed as Quality of Service (QoS)

• QoS for continous data streams mainly concern timeliness, volume, and reliability

• Properties for QoS:– The required bit rate at which data should be transported– The maximum delay until a session has been set up – The maximum end-to-end delay – The maximum delay variance, or jitter– The maximum round-trip delay

CIS017-6 Distributed and Parallel Architecture

Page 18: Cis017 6 revision-2015_distributed

Enforcing QoS

Using a buffer to reduce jitter.

CIS017-6 Distributed and Parallel Architecture

Page 19: Cis017 6 revision-2015_distributed

Enforcing QoS

The effect of packet loss in (a) non interleaved transmission and (b) interleaved transmission.

CIS017-6 Distributed and Parallel Architecture

Page 20: Cis017 6 revision-2015_distributed

Grid and Cloud Computing

• Grid Computing– Sharing resources– Virtualization– Types of Grid

• Cloud Computing– Providing services– Characteristics– Service Models (SaaS, PaaS, IaaS)– Deployment Models (private, community, public, hybrid)– Advantages and disadvantages

• Compare Grid Computing with Cloud Computing

Page 21: Cis017 6 revision-2015_distributed

Cloud Computing Characteristics• On-demand self-service• Broad network access• Resource pooling• Rapid elasticity• Measured service

Page 22: Cis017 6 revision-2015_distributed

Web Services• Web Services are

– self-contained, – modular

applications that can be– described -> using WSDL– published -> to UDDI– found -> in UDDI– bound -> using SOAP– invoked -> using SOAP– composed -> Orchestration

• SOAP, RESTful API

S ervic esP rovider

S erv ic esR eques ter

S erv ic esBroker F ind

W e b S e rv ice s

Publish-find-bind

Page 23: Cis017 6 revision-2015_distributed

See also….• The essential reading from Hennessy and Patterson

(2012)– in BREO weeks 2, 3, 4 and 7

• The essential reading from Greaves (2015)– in BREO week 3

• Tutorial questions– in BREO weeks 2 and 4

• Distributed Computing – Test Your Knowledge Questions – BREO Weeks 9 and 10.

• Essential Reading by Tanenbaum/van Steen, Couloris (see lecture notes)