Table of contents
Architectural styles
It means the way that components are connected to each other.
Layered Architectures
The basic idea for the layered style is simple: components are organized in a layered fashion where a component at layer Lj can make a downcall to a component at a lower-level layer Li (with i < j) and generally expects a response. Only in exceptional cases will an upcall be made to a higher-level component.
Object-based & service-oriented architectures
In which the components are objects, connected to each other through procedure calls. Objects may be placed on different machines; calls can thus execute across a network.
Resource-based architectures
In which a distributed system is a collection of resources, individually managed by components. Resources may be added, removed, retrieved, and modified by remote applications. Resources are identified through a single naming scheme. One example is Amazon S3.
Basic operations
PUT | Create a new resource. |
GET | Retrieve the state of a resource in some representation. |
DELETE | Delete a resource. |
POST | Modify a resource by transferring to a new state. |
Publish-subscribe architectures
In which there is a strong separation between processing and coordination. The idea is to view a system as a collection of autonomously operating processes. In this model, coordination encompasses the communication and cooperation between processes.
Temporally coupled | Temporally decoupled | |
Referentially coupled | Direct | Mailbox |
Referentially decoupled | Event-based | Shared data space |
Middleware Organization
There are two important types of design patterns that are often applied to the organization of middleware: wrappers and interceptors. Each targets different problems, yet addresses the same goal for middleware: achieving openness. However, it can be argued that the ultimate openness is achieved when we can compose middleware at runtime.
Wrappers
A wrapper or adapter is a special component that offers an interface acceptable to a client application, of which the functions are transformed into those available at the component. In essence, it solves the problem of incompatible interfaces.
One way of extending systems with existing components is implementing a so-called broker, which is logically a centralized component that handles all the accesses between different applications. An often-used type is a message broker.
Interceptors
interceptor is nothing but a software construct that will break the usual flow of control and allow other code to be executed. Interceptors are a primary means for adapting middleware to the specific needs of an application. As such, they play an important role in making middleware open.
Modifiable middleware
Modifiable middleware is a concept that allows distributed applications to adapt to changes in the environment, such as mobility. This allows middleware to make changes on the fly, allowing for purposeful modifications without bringing the system down.
System Architecture
Centralized organizations
Simple client-server architecture
In the basic client-server model, processes in a distributed system are divided into two (possibly overlapping) groups. A server is a process implementing a specific service, for example, a file system service or a database service. A client is a process that requests a service from a server by sending it a request and subsequently waiting for the server’s reply.
Multitiered Architectures
In this organization, everything is handled by the server while the client is essentially no more than a dumb terminal, possibly with only a convenient graphical interface. There are, however, many other possibilities. Many distributed applications are divided into three layers: the user interface layer, the processing layer, and the data layer.
Decentralized organizations
A famous example of them is peer-to-peer architectures: in which processes are all equal, the functions that need to be carried out are represented by every process, and each process will act as a client and a server at the same time (acting as a servant).
Hybrid architectures
In which systems are deployed on the Internet where servers are placed at the edge of the network: the boundary between enterprise networks and the actual Internet.
Edge-server architecture as an example:
BitTorrent
Principle: search for a file F :
Lookup file at a global directory, then it returns a torrent file.
Torrent file contains a reference to a tracker: a server keeping an accurate account of active nodes that have (chunks of) F.
P can join the swarm, get a chunk for free, and then trade a copy of that chunk for another one with a peer Q also in the swarm.
Thank you, and goodbye!