ARCHITECTURES DR. TRN HI ANH Tham kho bi ging ca PGS. TS. H Quc - - PowerPoint PPT Presentation

architectures
SMART_READER_LITE
LIVE PREVIEW

ARCHITECTURES DR. TRN HI ANH Tham kho bi ging ca PGS. TS. H Quc - - PowerPoint PPT Presentation

1 DISTRIBUTED SYSTEMS CHAPTER 2 ARCHITECTURES DR. TRN HI ANH Tham kho bi ging ca PGS. TS. H Quc Trung 2 Organization of a distributed system: distinction between the logical organization and the physical


slide-1
SLIDE 1

DISTRIBUTED SYSTEMS

CHAPTER 2 ARCHITECTURES

1

  • DR. TRẦN HẢI ANH

Tham khảo bài giảng của PGS. TS. Hà Quốc Trung

slide-2
SLIDE 2

2

 Organization of a distributed system:  distinction

between the logical organization and the physical realization

 The logical organization: the collection of software

components that constitute the system  software architecture

 The physical realization: instantiate and place

software components on real machines  system architecture

slide-3
SLIDE 3

Outline

3

1.

Architectural styles

2.

System architectures

3.

Architectures versus Middleware

slide-4
SLIDE 4
  • 1. Architectural styles

4

slide-5
SLIDE 5

Architectural styles

5

 Layered architectures  Object-based architectures  Data-centered architectures  Event-based architectures

slide-6
SLIDE 6

1.1. Layered achitectures

 Each layer has its own

task

 Transparency

6

Layered fashion

slide-7
SLIDE 7

Layered architectures (con’t)

7

Application Presentation Session Transport Network Data link Physical

OSI model General DS architecture with Middleware

slide-8
SLIDE 8

1.2. Object-based architectures

8

  • Component: Object
  • Connector: (Remote) Procedure

call

  • Object Client & Object server
  • E.g. CORBA
slide-9
SLIDE 9

1.3. Event-based architectures

9

  • Communicate through the

propagation of events (optionally carry data)

  • Publish/Subscribe systems
  • Processes are loosely coupled
slide-10
SLIDE 10

1.4. Data-centered architecture

14

  • Communicate

through a common repository

slide-11
SLIDE 11

1.5. Microservices

15

 Monolithic  microservices  build an application as a suite of small

services, each running in its own process and are independently deployable.

 Benefits:

 Simpler To Deploy  Simpler To Understand  Reusability Across Business  Faster Defect Isolation  Minimized Risk Of Change

slide-12
SLIDE 12

Microservices

17

slide-13
SLIDE 13

Microservices

18

slide-14
SLIDE 14

Problem

19

slide-15
SLIDE 15

Container Orchestration tools

20

 Amazon ECS (EC2 Container Service)  Azure Container Service (ACS)  Cloud Foundry’s Diego  CoreOS Fleet  Docker Swarm  Kubernetes

slide-16
SLIDE 16

Kubernetes

21

API K K K

KBs Cluster Services

Master node Worker Worker Worker App1 config Pod1: + Cont1 + Cont2 Rep=3 Pod2: +Cont3 Rep=2 P1- R1 P1- R2 P1- R3 P2- R1 P2- R2

slide-17
SLIDE 17

I.

Centralized architectures

II.

Decentralized architectures

III.

Hybrid architectures

  • 2. System architectures

22

slide-18
SLIDE 18

2.1. Centralized architectures

23

2.1.1. Client-server architectures 2.1.2. Application layering 2.1.3. Multitiered architectures

slide-19
SLIDE 19

2.1.1. Client-server architecture

24

  • Client:
  • Send the requests, receive the results,

show to the users

  • Server:
  • Listen; receive the request,

processing, reply

  • Connected or unconnected
  • Issues:
  • Register the server
  • Idempotent
  • Stateful of Stateless server
slide-20
SLIDE 20

2.1.2. Application layering

25

 The user-interface level  The processing level  The data level

slide-21
SLIDE 21

Organization of a search engine

26

slide-22
SLIDE 22

2.1.3. Multitiered architectures

27

slide-23
SLIDE 23

28

slide-24
SLIDE 24

Cloud & Fog computing

29

slide-25
SLIDE 25

2.2. Decentralized Architectures

31

 No role of client and server  Use Overlay network  Structured/Unstructured P2P architectures

slide-26
SLIDE 26

Overlay network

32

slide-27
SLIDE 27

2.2.1. Structured P2P

33

 Overlay network is constructed using a

deterministic procedure.

 DHT (Distributed Hash Table)

slide-28
SLIDE 28

Chord system

34

  • Logically organized in a

ring

  • Succ(k)
  • Function LOOKUP(k)
  • When a node wants to

join the system

  • When a node wants to

leave the system

slide-29
SLIDE 29

CAN system (Content Addressable Network)

35

slide-30
SLIDE 30

2.2.2. Unstructured P2P architecture

36

 Randomized algorithms for constructing an overlay

network.

 Each node maintains a list of neighbors  Data items are assumed to be randomly placed on

nodes  locating a specific data item needs flooding the network

 =>superpeers

slide-31
SLIDE 31

2.3. Hybrid architectures

37

 Edge-Server Systems  Collaborative Distributed Systems

slide-32
SLIDE 32

Edge-Server Systems

38

slide-33
SLIDE 33

Content Delivery Network

39

slide-34
SLIDE 34

Collaborative Distributed Systems

40

BitTorrent system

slide-35
SLIDE 35
  • 3. Architectures versus Middleware

41

slide-36
SLIDE 36

Where does Middleware fit in?

42

 Position of middleware  E.g. CORBA (object-based architecture),

TIB/Rendezvous (event-based architecture)

 Benefit: designing applications may become simpler  Drawback: no longer be optimal for application

developers

 Solutions:

 make several versions of a middleware system  separate between policies and mechanisms  easy to

configure, adapt and customize middleware

slide-37
SLIDE 37

Interceptors

 software

construct  break the usual flow of control and allow other code to be executed

43