Topic | Centralized | Decentralized | Distributed Systems |
---|---|---|---|
Definition | uses client/server architecture where one or more client nodes are directly connected to a central server. The central owner stores data, which other users can access, and also user information. This user information may include user profiles, user-generated content, and more. |
every node makes its own decision. The final behavior of the system is the aggregate of the decisions of the individual nodes. Note that there is no single entity that receives and responds to the request. decentralized systems don’t have one central owner. Instead, they use multiple central owners, each of which usually stores a copy of the resources users can access (one or more central owners or servers fail, the others can continue to provide data access to users.) |
every node makes its own decision. The final behaviour of the system is the aggregate of the decisions of the individual nodes. Note that there is no single entity that receives and responds to the request. distributed system enables users to share ownership of the data, In a distributed system, users have equal access to data, though user privileges can be enabled when needed. |
Architecture | Client-Server architecture. The central node that serves the other nodes in the system is the server node and all the other nodes are the client nodes. |
master-slave architecture – One node can become a master by voting and help in coordinating of a part of the system but this does not mean the node has supremacy over the other node which it is coordinating | peer-to-peer – all nodes are peer of each other and work towards a common goal client-server – some nodes are become server nodes for the role of coordinator, arbiter, etc. n-tier architecture – different parts of an application are distributed in different nodes of the systems and these nodes work together to function as an application for the user/client |
Example | Wikipedia. Consider a massive server to which we send our requests and the server responds with the article that we requested. Suppose we enter the search term ‘junk food’ in the Wikipedia search bar. | KYC chain for SSI from Self key Brave web browser |
Bitcoin. Lets take bitcoin for example because its the most popular use case of decentralized systems. No single entity/organisation owns the bitcoin network. The network is a sum of all the nodes who talk to each other for maintaining the amount of bitcoin every account holder has. |
Key features | Presence of a global clock: As the entire system consists of a central node(a server/ a master) and many client nodes(a computer/ a slave), all client nodes sync up with the global clock(the clock of the central node). | Lack of a global clock: Every node is independent of each other and hence, have different clocks that they run and follow. | Lack of a global clock: All nodes maintain their own clock. |
One single central unit: One single central unit which serves/coordinates all the other nodes in the system. | Multiple central units (Computers/Nodes/Servers): More than one central unit which can listen for connections from other nodes | Concurrency of components: Nodes apply consensus protocols to agree on same values/transactions/commands/logs. | |
Dependent failure of components: Central node failure causes entire system to fail. This makes sense because when the server is down, no other entity is there to send/receive response/requests | Dependent failure of components: one central node failure causes a part of system to fail; not the whole system | Independent failure of components: In a distributed system, nodes fail independently without having a significant effect on the entire system. If one node fails, the entire system sans the failed node continue to work | |
Scalability | Only vertical scaling on central server is possible. Horizontal scaling will contradict the single central unit characteristic of this system of a single central entity. | Vertical scaling is possible. Each node can add resources(hardware, software) to itself to increase the performance leading to increase in performance of the entire system. | Horizontal and vertical scaling is possible |
Limitations | Can’t scale up vertically after a certain limit – After a limit, even if you increase the hardware and software capabilities of the server node, the performance will not increase appreciably leading to a cost/benefit ratio < 1. | May lead to problem of coordination at the enterprise level – When every node is owner of its own behavior, its difficult to achieve collective tasks | Difficult to design and debug algorithms for the system. These algorithms are difficult because of the absence of a common clock; so no temporal ordering of commands/logs can take place. Nodes can have different latencies which have to be kept in mind while designing such algorithms |
Bottlenecks can appear when the traffic spikes – as the server can only have a finite number of open ports to which can listen to connections from client nodes. So, when high traffic occurs like a shopping sale, the server can essentially suffer a Denial-of-Service attack or Distributed Denial-of-Service attack. | Not suitable for small systems – Not beneficial to build and operate small decentralized systems because of low cost/benefit ratio | No common clock causes difficulty in the temporal ordering of events/transactions. Difficult for a node to get the global view of the system and hence take informed decisions based on the state of other nodes in the system |
|
Advantages | easy to secure and service the server and client nodes by virtue of their location | Minimal problem of performance bottlenecks occurring – The entire load gets balanced on all the nodes; leading to minimal to no bottleneck situations | Low latency than centralized system – Distributed systems have low latency because of high geographical spread, hence leading to less time to get a response |
can be modified to suit custom needs Dedicated resources (memory, CPU cores, etc) |
High availability – Some nodes(computers, mobiles, servers) are always available/online for work, leading to high availability | More distributed decision making | |
cost efficient for small systems upto a certain limit – As the central systems take less funds to set up, they have an edge when small systems have to be built | More autonomy and control over resources – As each node controls its own behavior, it has better autonomy leading to more control over resources | ||
Easy of maintenance and detachment of a node from the system. | |||
Disadvantages | Highly dependent on the network connectivity | Difficult to achieve global big tasks – No chain of command to command others to perform certain tasks | Difficult to achieve consensus |
No graceful degradation of system – abrupt failure of the entire system | Complicated architecture - Difficult to know which node failed /responded | Conventional way of logging events by absolute time they occur is not possible here | |
There is only one server node and due to availability reasons, it is inefficient and unprofessional to take the server down for maintenance. | Compute intensive | Compute intensive | |
Less possibility of data backup. If the server node fails and there is no backup, you lose the data straight away | HIgher maintenance & orchestration/synchronization efforts | HIgher maintenance & orchestration/synchronization efforts | |
Applications | Application development – Very easy to setup a central server and send client requests. | Private networks – peer nodes joined with each other to make a private network. | Cluster computing – a technique in which many computers are coupled together to work so that they achieve global goals. The computer cluster acts as if they were a single computer |
Data analysis – Easy to do data analysis when all the data is in one place | Consortium based apps ( supply chain/banks etc.) involving mulitple stakeholders & consensus | Grid computing – All the resources are pooled together for sharing in this kind of computing turning the systems into a powerful supercomputer; essentially | |
Single player games like Need For Speed, GTA Vice City – entire game in one system | Cryptocurrency – Nodes joined to become a part of a system in which digital currency is exchanged without any trace and location of who sent what to whom. | ||
personal computer | Decen browsers/chat tools/social media | Distri code mangement, data control & sharing - Git/ Internet/Bitcoin | |
PROS | Simple deployment Can be developed quickly Affordable to maintain Practical when data needs to be controlled centrally |
Less likely to fail than a centralized system Better performance Allows for a more diverse and more flexible system |
Fault-tolerant Transparent and secure Promotes resource sharing Extremely scalable |
CONS | Prone to failures Higher security and privacy risks for users Longer access times to data for users who are far from the server |
Security and privacy risks to users Higher maintenance costs Inconsistent performance when not properly optimized |
More difficult to deploy Higher maintenance costs Higher development effort |
Created
April 30, 2021 10:09
-
-
Save vikpande/fbec7e73346600733455d3c463601647 to your computer and use it in GitHub Desktop.
Centralised, Decentralised & Distributed system notes
Author
vikpande
commented
Apr 30, 2021
Fault tolerance | Maintenance & Scalability | Development | Evolution |
---|---|---|---|
Low: Centralized systems | Low: Centralized systems | Moderate: Decentralized systems, Distributed systems | Low: Centralized systems |
Moderate: Decen. systems | Moderate: Decen. systems | High: Centralized systems | High: Decentralized systems, Distributed systems |
High: Distributed systems | High: Distributed systems |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment