当前位置:网站首页>System design: key features of distributed systems
System design: key features of distributed systems
2022-06-24 10:52:00 【Xiaochengxin post station】
Key features of distributed systems include scalability 、 reliability 、 Usability 、 Efficiency and manageability . Let's briefly review
Scalability ( Including scalability )
Scalability is the system 、 The ability of a process or network to grow and manage growing demand . Any distributed system that can evolve to support an increasing workload is considered scalable .
Due to the increase of data volume or workload ( For example, the number of transactions ) And so on , The system may have to be extended . A scalable system hopes to achieve this kind of expansion without losing performance . Generally speaking , Although the performance of the system is designed ( Or claim ) Is scalable , But for management or control reasons , Decreases with the size of the system
Environmental costs . for example , The network may slow down , Because machines are often far apart . More generally , Some tasks may not be distributed , This may be due to their inherent atomic properties , It may also be due to some defects in the system design . In a way , Such a task will limit the speed of the assignment . The scalable architecture avoids this , And try to balance the load on all participating nodes .
Horizontal and vertical expansion :
Horizontal scaling means scaling by adding more servers to the resource pool ( That is what we often call a heap machine ), Vertical expansion means adding more power to existing servers (CPU、RAM、 Storage, etc ) To expand .
Expand horizontally , By adding more machines to the existing pool , It is often easier to dynamically extend ; Vertical expansion is usually limited to the capacity of a single server , Scaling beyond this capacity usually involves downtime , And there is an upper limit .
A good example of horizontal expansion is Cassandra and MongoDB, Because they all meet the growing demand by adding more machines , Thus, a simple horizontal expansion method is provided . Similarly , A good example of vertical scaling is MySQL, Because it allows vertical scaling by switching from a smaller machine to a larger machine . However , This process often involves downtime .
reliability ( High availability 、 stability )
According to the definition , Reliability is the probability that a system will fail within a given period of time. For example, we often say that it is often unavailable throughout the year , There are several goals to achieve stability 9. In short , If a distributed system can still provide services when one or more software or hardware components fail , Then it is considered reliable . Reliability represents one of the main characteristics of any distributed system , Because in a system like this , Any malfunctioning machine can be replaced by another normal machine , To ensure that the requested task is completed .
Take large e-commerce stores ( Such as Amazon) For example , One of the main requirements is , No user transaction should be canceled because the machine running the transaction fails . for example , If the user has added an item to their cart , Then the system will not lose it . Reliable distributed systems achieve this through redundancy of software components and data . If the server hosting the user's shopping cart fails , Then another server with an exact copy of the shopping cart should replace it .
obviously , Redundancy comes at a price , And a reliable system must pay the price , Only by eliminating each failure point can the service recovery be realized .
Usability
Availability is also used as CAP and BASE Medium A theory , The system must be available . According to the definition , Availability is the time that a system remains running to perform its required functions for a specific period of time . It's about the system 、 A simple measure of the percentage of time a service or machine remains running under normal conditions . A plane that can fly several hours a month without stopping can be said to be highly available . Availability considers maintainability 、 Maintenance time 、 Spare parts availability and other logistics factors . If the aircraft is stopped for maintenance , Is considered unavailable during this period .
Reliability is the availability over a period of time taking into account the various situations that may occur in the real world . An aircraft that can safely fly in any possible weather is more reliable than an aircraft that is susceptible to possible conditions .
reliability VS Usability
If a system is reliable , It's available . However , If available , Not necessarily reliable . let me put it another way , High reliability contributes to high availability , But by minimizing maintenance time and ensuring spare parts availability , Even if the product is unreliable , It is also possible to achieve high availability
Available whenever needed . Let's take an online retail store as an example , It has... In the first two years after its launch 99.99% The usability of . However , The system did not conduct any information security test at startup . The customer was very satisfied with this system , But they didn't realize it wasn't reliable , Because it is very susceptible to risk . In the third year , The system has experienced a series of information security events , These events suddenly lead to very low availability for a long time . This will damage the customer's reputation and finances .
efficiency
To understand how to measure the efficiency of Distributed Systems , Suppose we have an operation that runs in a distributed manner , And deliver a set of items as a result . The two standard measures of its efficiency are the response time that represents the delay in obtaining the first item ( Or delay ) And denote in a given time unit ( for example , second ) Throughput of the number of items delivered in ( Or bandwidth ). These two measures correspond to the following unit costs :
• Regardless of message size , The number of messages sent globally by the system node .
• Message size indicating data exchange volume .
The complexity of the operations supported by distributed data structures ( for example , Search the distributed index for specific keys ) A function that can be described as one of these cost units . Generally speaking , use “ The number of messages ” It is too simple to analyze the distributed structure . It ignores the impact of many aspects , Including network topology 、 Network load and its changes 、 Possible heterogeneity of software
However , It is difficult to build an accurate cost model to accurately consider all these performance factors ; therefore , We have to accept rough and robust estimates of system behavior .
RT and throughout It is generally used as the benchmark index to measure the efficiency of the system .
Maintainability or manageability
When designing distributed systems , Another important consideration is how easy it is to operate and maintain . Serviceability or manageability is the simplicity and speed of system repair or maintenance ; If the time to repair the faulty system increases , Then the availability will be reduced . Manageability needs to be considered : When problems happen , How easy it is to diagnose and understand the problem 、 How easy it is to update or modify , And the simplicity of the system operation ( namely , Whether the system operates normally without fault or abnormality ?).
Early fault detection can reduce or avoid system downtime . for example , When a system failure occurs in the system , Some enterprise systems can automatically call the service center ( No manual intervention required ).
A good distributed system , Some of the most basic key features are described above , Think about whether your system is a good distributed system ? It conforms to the core reference features mentioned above ?
Reference material :
边栏推荐
- The latest entry date of SQL Sever test questions
- Flink checkpoint and savepoint
- Cool interactive animation JS special effects implemented by p5.js
- [IEEE publication] 2022 International Conference on service robots (iwosr 2022)
- Niuke-top101-bm29
- Distributed transaction principle and solution
- 多线程的应用 - 提升效率
- A group of skeletons flying canvas animation JS special effect
- Leetcode-2221: triangular sum of arrays
- Cross domain overview, simple accumulation
猜你喜欢

Cool interactive animation JS special effects implemented by p5.js

腾讯开源项目「应龙」成Apache顶级项目:前身长期服务微信支付,能hold住百万亿级数据流处理...

进程与多线程

Cookie 、Session、localstorage、Sessionstorage的区别

多线程的应用 - 提升效率

Flink checkpoint and savepoint

喜欢就去行动

Canvas falling ball gravity JS special effect animation

【IEEE出版】2022年自然语言处理与信息检索国际会议(ECNLPIR 2022)

JMeter interface test tool foundation - sampler (II)
随机推荐
Web project deployment
抓包工具charles实践分享
Apple's legendary design team disbanded after jobs refused to obey cook
Fais ce que tu veux.
【IEEE出版】2022年自然语言处理与信息检索国际会议(ECNLPIR 2022)
[resource sharing] 2022 International Conference on Environmental Engineering and Biotechnology (coeeb 2022)
Canvas falling ball gravity JS special effect animation
A group of skeletons flying canvas animation JS special effect
Thread pool execution process
Flink checkpoint and savepoint
栈题目:函数的独占时间
Multithreaded applications - improve efficiency
Charles packet capturing tool tutorial
What is the function of the graphics card driver? Do you want to update the graphics card driver
Window function row in SQL Server_ number()rank()dense_ rank()
Leetcode-223: rectangular area
Process and multithreading
线程运行原理
Appium automation test foundation - mobile end test environment construction (I)
Dedecms template file explanation and homepage label replacement