Distributed Systems Architectures: Exam Q&A, Exams of Computer Science

A question and answer format overview of distributed systems architectures, covering topics such as software and system architecture, communication protocols, object-based and service-oriented architectures, restful architecture, publish-subscribe architectures, middleware design patterns, and centralized and decentralized system organizations. It also includes examples and explanations of key concepts like tcp, proxies, service composition, and p2p systems, making it a useful resource for exam preparation and understanding the fundamentals of distributed systems.

Typology: Exams

2025/2026

Available from 09/08/2025

Matress
Matress 🇺🇸

3K documents

1 / 7

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
DISTRIBUTED SYSTEMS CHAPTER 2 ARCHITECTURES
EXAM QUESTIONS AND ANSWERS
Software architecture - ANSWER tell us how the software components are
organized and how they interact
How can we separate applications from the underlying platforms? - ANSWER
- use a middleware layer which provides distribution transparency
System architecture - ANSWER - the final instantiation of a software
architecture where it goes on real machines
- this can include centralized or decentralized architecture
component - ANSWER a modular unit with well-defined interfaces and are
replaceable, while the system continues to operate
4 architectural styles - ANSWER - layered architecture (components are
organized in a heirarchy making calls down the layers)
- Object-based architecture
- resource-centered architecture
- Event-based architecture
communication protocol stacks - ANSWER each layer implements a
communication service with the layer offering an interface for functions that
can be called and allowing data to be sent to one or several targets
- communication protocol describes the rules that parties must follow to
exchange info
Transmission Control Protocol (TCP) - ANSWER - provides reliable, ordered,
and error-checked delivery of a stream of packets on the internet
- AF_NET and SOCK_STREAM are used to specify that the TCP protocol
should be used to communicate between two parties
Three logical levels in Application layering - ANSWER * application-
interface level
* processing level
pf3
pf4
pf5

Partial preview of the text

Download Distributed Systems Architectures: Exam Q&A and more Exams Computer Science in PDF only on Docsity!

DISTRIBUTED SYSTEMS CHAPTER 2 ARCHITECTURES

EXAM QUESTIONS AND ANSWERS

Software architecture - ANSWER tell us how the software components are organized and how they interact How can we separate applications from the underlying platforms? - ANSWER

  • use a middleware layer which provides distribution transparency System architecture - ANSWER - the final instantiation of a software architecture where it goes on real machines
  • this can include centralized or decentralized architecture component - ANSWER a modular unit with well-defined interfaces and are replaceable, while the system continues to operate 4 architectural styles - ANSWER - layered architecture (components are organized in a heirarchy making calls down the layers)
  • Object-based architecture
  • resource-centered architecture
  • Event-based architecture communication protocol stacks - ANSWER each layer implements a communication service with the layer offering an interface for functions that can be called and allowing data to be sent to one or several targets
  • communication protocol describes the rules that parties must follow to exchange info Transmission Control Protocol (TCP) - ANSWER - provides reliable, ordered, and error-checked delivery of a stream of packets on the internet
  • AF_NET and SOCK_STREAM are used to specify that the TCP protocol should be used to communicate between two parties Three logical levels in Application layering - ANSWER * application- interface level
  • processing level
  • data level (data is persistent and responsible for keeping data consistent across apps) Object-based and Service-oriented Architectures - ANSWER - each object is a component and components are connected through procedure calls
  • benefits: encapsulate data (called an objects state) and the operations (or methods) into a single entity
  • when a client binds to a distributed object the implementation of the object's interface, called a proxy, is loaded into the client's address space proxy - ANSWER - the implementation of an object interface
  • it mashal's method invocations into messages and unmarshals reply messages to return the result of the method invocation to the client
  • incoming invocations from the client are passed to a server stub called a skeleton, which unmarshals the request to make method invocations at the object interface remote objects - ANSWER - a distributed object where the state is not distributed (its on a single machine)
  • only the interfaces implemented by the object are available on other machines In service-oriented architecture (SOA) a distributed app is a composition of many _______ - ANSWER - different services that may not all belong to the same administrative org
  • thus SOA is based on service composition One of the problems with service composition - ANSWER - connecting different components can turn into an integration nightmare An alternative to service composition that helps deal with integration hassles - ANSWER - resource based architectures
  • the distributed system is a huge collection of resources managed by components where resources can be added or removed Representational State Transfer (REST) architecture - ANSWER 1. Resources are identified through a single name scheme
  1. All services offer the same interface consisting of four operations at most (PUT, GET, DELETE, POST)
  1. interceptors = a software construct that breaks the flow of control to allow other app specific code to be executed both have the goal of openness and are a means to extend and adapt middleware broker - ANSWER - reduces the number of wrappers through middleware
  • a centralized component that handles all accesses between different applications
  • the broker has knowledge of all relevant apps request-level interceptor - ANSWER it will invoke a call for each of the replicas and the object calling does not need to be aware of the replication and the object middleware need not have special components to deal with the replication modifiable middleware - ANSWER - we should be able to adapt it and modify it without bringing it down
  • including dynamically constructing middleware from components Example of centralized organization in System Architecture - ANSWER - client-server architecture: clients making requests to services on servers and the client waits for a reply
  • this is hard to distinguish between client-server for a distributed database since the server for the db may just be forwarding requests to different servers responsible for the tables Three-tiered architecture - ANSWER - a server may sometimes need to act as a client
  • common in transaction processing and web sites Vertical Distribution - ANSWER - placing logically different components on different machines
  • like multi-tiered architecture Horizontal Distribution - ANSWER - a client or server may be physically split up, but each part is operating on its own share of the complete data set to balance the load
  • like peer-to-peer systems

Peer-to-peer systems - ANSWER - much of the interaction between processes is symetric where each process acts as both client and server (also called servant)

  • uses an overlay network, where the nodes are formed by processes and the links are communication channels and nodes that can not talk directly instead send messages through available comm channels Structured P2P - ANSWER - nodes are organized in an overlay like a ring or binary tree so that it can efficiently look up data
  • any node can be asked to look up a key, so it boils down to efficiently routing a request to the node storing it
  • a hashing function can be used to identify the node responsible for storing the tiem Unstructured P2P - ANSWER each node maintains an ad hoc list of neightbors
  • the resulting overlay is a random graph, where an edge between nodes only exists with a certain probability
  • it starts by contacting a well-known node and then obtains a list of other peers
  • to request data you can search with flooding or random walks Flooding - ANSWER - an issuing node passes a request for data to all its known neighbors, a request is ignored when the receiving node has seen it before otherwise the node searches for it among its neighbors or sends the data back to the issuing node
  • often has a time-to-live, the max # of hops it can be forwarded since it can be expensive Random Walks - ANSWER - issing node can ask a random neighbor, then that node forwards it to a random neightbor
  • this has less network traffic, but takes much longer to find the data
  • increase the speed by starting n random walks simultaneously P2P Alternatives to just searching using random walks and flooding - ANSWER - use super peers in a hierarchical organization:
  • make use of special nodes that have an index of data items
  • or use a broker that collects data on usage and availability to allow nodes to quickly access resources in a CDN, content delivery network

Server-Side Script - ANSWER executed by the server when the doc has been fetched locally the result of execution is sent along with the rest of the doc to the client