Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

Distributed Systems Architecture and Processes: A Week 2 Assignment for COP 5615, Lecture notes of Distributed Programming and Computing

An overview of various architectural styles in distributed systems, including layered, resource-based, centralized, decentralized, structured peer-to-peer, and unstructured peer-to-peer architectures. Additionally, it discusses the concepts of processors, processes, and threads, their differences, and the importance of context switching in managing multiple threads. A weekly assignment for the course cop 5615: distributed operating system principles.

Typology: Lecture notes

2019/2020

Uploaded on 10/19/2020

saurabh-prasad
saurabh-prasad 🇺🇸

5

(3)

5 documents

1 / 1

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
COP 5615: Distributed Operating System Principles | Weekly Assignment Week 2: 26-30 August
Architecture
There are multiple architectural styles when It comes to designing a system.
Layered Architecture: It consists of multiple layers where each layer provides a different service. It
offers very good separation of concern for developing scalable, production grade, distributed, relatively
risk-free applications. Ex. Communication Protocols (TCP/IP has 4 layers).
Resource based architecture: System that follow the RESTful design criteria. The system is a collection
of resources which may be added, removed, retrieved and modified by applications via operations like
GET, POST, PUT, DELETE. Ex. Amazon AWS S3 (http://BucketName.s3.amazonaws.com/ObjectName).
Centralized system Architecture: It uses client/server architecture where one or more client nodes are
connected to a central server (can be on different machine). Clients follow request/reply model for using
services. Disadvantages are Its difficult to scale vertically and there is a single point of failure.
Decentralized Architecture: No single entity is responsible for receiving and responding to requests. No
single point of failure. Example Torrent network, blockchain and its applications like bitcoin. No single
entity/organization owns the bitcoin network. It can be-
Structured Peer to peer: Makes use of semantic-free Index (hash function) to assign values to every peer
and content where each peer is responsible for specific part of content. Ex chord (nodes in a ring).
Unstructured Peer to peer: Overlay links are created arbitrarily where each node maintains an ad hoc list
of neighbors. Is easy to add a new node. Searching for data is done by flooding (node passing request to
all neighbors) or Random walk (node passing request to randomly chosen node).
Hybrid Architecture: To provide tangible increase in data access speed an edge server system can be
used where servers are placed at edge of the network. Ex. Netflix uses this to reduce latency and
improve performance while distributing their content to their users.
Processes and Threads
Processors: are physical hardware. It has the capability to execute a series of instructions. We build
virtual processor on top of physical ones.
Process: is software processor in whose context a series of instructions can be executed.
Thread: is a minimal software processor which executes in context of a process. It has all the data
needed for instruction execution. Multiple threads can run under same process.
We use multiple threads to exploit parallelism on a multiprocessor and avoid needless blocking when
performing I/O leveraging context-switching.
Context Switching is the process of saving the context of one thread/process and loading the context of
another thread/process.
Process switching involves switching the memory address space like memory address, mapping, page
tables, kernel resources (might involve flushing cache). Thread switching involves switching abstractions
unique to thread like program counter and register state which is much cheaper.
So, Process context switching is expensive than thread context switching and should be avoided.
-Saurabh K Prasad (UFID: 3417-8993)

Partial preview of the text

Download Distributed Systems Architecture and Processes: A Week 2 Assignment for COP 5615 and more Lecture notes Distributed Programming and Computing in PDF only on Docsity!

COP 5615: Distributed Operating System Principles | Weekly Assignment Week 2: 26-30 August Architecture There are multiple architectural styles when It comes to designing a system. Layered Architecture: It consists of multiple layers where each layer provides a different service. It offers very good separation of concern for developing scalable, production grade, distributed, relatively risk-free applications. Ex. Communication Protocols (TCP/IP has 4 layers). Resource based architecture : System that follow the RESTful design criteria. The system is a collection of resources which may be added, removed, retrieved and modified by applications via operations like GET, POST, PUT, DELETE. Ex. Amazon AWS S3 (http://BucketName.s3.amazonaws.com/ObjectName). Centralized system Architecture: It uses client/server architecture where one or more client nodes are connected to a central server (can be on different machine). Clients follow request/reply model for using services. Disadvantages are Its difficult to scale vertically and there is a single point of failure. Decentralized Architecture: No single entity is responsible for receiving and responding to requests. No single point of failure. Example Torrent network, blockchain and its applications like bitcoin. No single entity/organization owns the bitcoin network. It can be- Structured Peer to peer: Makes use of semantic-free Index (hash function) to assign values to every peer and content where each peer is responsible for specific part of content. Ex chord (nodes in a ring). Unstructured Peer to peer: Overlay links are created arbitrarily where each node maintains an ad hoc list of neighbors. Is easy to add a new node. Searching for data is done by flooding (node passing request to all neighbors) or Random walk (node passing request to randomly chosen node). Hybrid Architecture: To provide tangible increase in data access speed an edge server system can be used where servers are placed at edge of the network. Ex. Netflix uses this to reduce latency and improve performance while distributing their content to their users. Processes and Threads Processors: are physical hardware. It has the capability to execute a series of instructions. We build virtual processor on top of physical ones. Process : is software processor in whose context a series of instructions can be executed. Thread: is a minimal software processor which executes in context of a process. It has all the data needed for instruction execution. Multiple threads can run under same process. We use multiple threads to exploit parallelism on a multiprocessor and avoid needless blocking when performing I/O leveraging context-switching. Context Switching is the process of saving the context of one thread/process and loading the context of another thread/process. Process switching involves switching the memory address space like memory address, mapping, page tables, kernel resources (might involve flushing cache). Thread switching involves switching abstractions unique to thread like program counter and register state which is much cheaper. So, Process context switching is expensive than thread context switching and should be avoided. -Saurabh K Prasad (UFID: 3417-8993)