当前位置:网站首页>Cap theory sounds very big, but it's actually very simple
Cap theory sounds very big, but it's actually very simple
2022-06-11 11:12:00 【zhanyd】
CAP The theory sounds very big , It's very simple .
Uniformity (Consistency): Make sure the data is consistent , Right
Usability (Availability): Ensure that the system can be used
Partition tolerance (Partition Tolerance): Even if the network goes wrong ( Partition ), I can bear
In distributed systems , The network is bound to go wrong , ineluctable , For example, the server hangs up , The program is up , The cable was kicked off , Network timeout and so on .
The servers were originally connected through the network , In one piece , In a large area , Synchronize data with each other , Now there is something wrong with the network , The servers are disconnected , They are isolated from each other , The data cannot be synchronized , This forms the partition .
A partition appears , We did, too , This is a network error , It's inevitable , So partition fault tolerance is P, It has always existed in distributed systems .
That's in P Under the premise of existence , We choose to guarantee : It is important that the data is correct (CP), It is more important to ensure that the system can be used (AP)?
CP: such as A The data of the server should be synchronized to B Server's , Now the network is down ,A The data can not be transmitted , I think it's important to guarantee the data , If A and B It's not right , The consequences are serious , In order to ensure A and B The data on the server is consistent , Just let A Stop the service , Return error information directly to the client , When the network is restored , Go online again , lest A and B The data are inconsistent .
AP: such as A The data of the server should be synchronized to B Server's , Now the network is down ,A The data can not be transmitted , I think it doesn't matter if the data are inconsistent temporarily , The most important thing is that the system can be used , Then I will continue to let A Provide services , When the network is restored , Resynchronize data to B.
CAP The problem is that the network is not working , We give priority to data consistency , The priority is to ensure the availability of the system .

边栏推荐
- 企业微信小程序避坑指南,欢迎补充。。。
- Digital collection system app source code
- SQL query statement optimization
- Package component series - (I) - slots and dynamic components
- Tu ne peux pas être libre sans richesse?
- Introduction to database system - Chapter 2 - relational database (2.1~2.3) (important knowledge points)
- 使用Yolov5训练自己制作的数据集,快速上手
- Jerry's acquisition of ble distinguishes between reset and wake-up [chapter]
- 外观模式--在各种套餐中早就用到啦!
- 杰理之获取 BLE 区分复位跟唤醒【篇】
猜你喜欢

VOC格式数据集转yolo格式数据集的方法
![[CV basis] Color: rgb/hsv/lab](/img/0f/188b103bc910b1a635b8f421f38ec2.png)
[CV basis] Color: rgb/hsv/lab

(key points of software engineering review) Chapter IV overall design exercises

把程序写进微控制器里可以更方便快捷的控制电机正反转
![Jerry's ble chip power supply range and anti burn chip measures [chapter]](/img/25/f35ca0366d31a70cd5e487347bb814.png)
Jerry's ble chip power supply range and anti burn chip measures [chapter]

MySQL download, installation and use - complete and detailed steps
![Set the default receiving address [project mall]](/img/eb/2864b124b66d01849315a367948ed4.png)
Set the default receiving address [project mall]

使用Yolov5训练自己制作的数据集,快速上手

袋鼠云数栈基于CBO在Spark SQL优化上的探索

Team level safety training, new employee induction training education courseware, full content ppt application
随机推荐
使用Yolov5训练自己制作的数据集,快速上手
MySQL download, installation and use - complete and detailed steps
What is the best annuity insurance product in 2022?
杰理之BLE SPP 开启 pin_code 功能【篇】
数据库系统概论 ---- 第二章 -- 关系数据库(2.1~2.3)(重要知识点)
Team level safety training, new employee induction training education courseware, full content ppt application
Can't you be free without wealth?
Half of the property rights of the house are registered in the woman's name when they are in love, and they want to return after they break up
2022北京国际营养健康产业博览会,第九届中国大健康产业展会
SpingBoot+Quartrz生产环境的应用支持分布式、自定义corn、反射执行多任务
AcWing 1944. 记录保存(哈希,STL)
Xiao P weekly Vol.08
Use yolov3 to train yourself to make datasets and get started quickly
Electron desktop development (development of an alarm clock [End])
启牛帮开通的证券账户是安全可信的吗?
Droid-slam: depth vision slam for monocular and binocular rgbd cameras
Rxjs Observable. Execute logical analysis of pipe passing in multiple operators
迭代器模式--沙场秋点兵
Using domestic MCU (national technology n32g031f8s7) to realize pwm+dma control ws2812
Taking the cooperation between different banks as an example, the construction of small program ecology