当前位置:网站首页>MYSQL two-phase commit
MYSQL two-phase commit
2022-08-01 01:11:00 【March is immortal】
MYSQL two-phase commit
Binlog and redolog both record data. When recording data, whether to write binlog or redolog first, there will be problems whether redolog or binlog is written first. Both files must be written or not written.If the redolog is written and the binlog is not written, it may cause data inconsistency
Both binlog and redolog will record data at the same time, so what is the order of their records?
Execution process:
1. The executor first finds the data from the engine, if it returns directly in the memory, if it is not in the memory, it returns after the query
2. After the executor gets the data, it will first modify the data, and then call the engine interface to rewrite the data
3. The engine updates the data to the memory and writes the data to the redo at the same time. At this time, it is in the prepare stage and informs the executor that the execution is completed, and can be operated at any time.
4.The executor generates the binlog of this operation
5. The executor calls the transaction commit interface of the engine, the engine changes the redo that has just been written to the commit state, and the update is completed
Two Phase Commit
边栏推荐
- Compose principle - the view and the principle of two-way data binding
- ROS2系列知识(4): 理解【服务】的概念
- Google engineer fired for claiming AI awareness: breach of nondisclosure agreement
- Force buckle 2326, 197
- Nmap Operation Manual - Full Version
- Compose原理-视图和数据双向绑定的原理
- leetcode:1562. 查找大小为 M 的最新分组【模拟 + 端点记录 + 范围合并】
- sqlserver无法远程连接
- MYSQL经典面试题
- Redis五种数据类型简介
猜你喜欢
随机推荐
GDB 源码分析系列文章五:动态库延迟断点实现机制
欧拉系统(euleros):升级Mysql
500 miles
In 2022, the latest eight Chongqing construction members (electrical construction workers) simulation question bank and answers
精心总结十三条建议,帮你创建更合适的MySQL索引
Matlab / Arcgis处理nc数据
OSF understands the agile development model in one minute
[AMEX] LGBM Optuna美国运通信用卡欺诈赛 kaggle
RTL8762DK WDG (six)
【 】 today in history: on July 31, "brains in vats" the birth of the participant;The father of wi-fi was born;USB 3.1 standard
By Value or By Reference
JS时间戳的意义是什么?知道sql会考虑加时间戳,JS的时间戳用于什么场景?
Rasa 3.x Learning Series - Using Lookup Tables to Improve Entity Extraction
YOLO怎么入门?怎么实现自己的训练集?
MYSQL逻辑架构
STK8321 I2C (Shengjia-accelerometer) example
An open source and easy-to-use flowchart drawing tool drawio
Classes and Objects: Above
RTL8762DK RTC (5)
【数据分析】基于matlab GUI学生成绩管理系统【含Matlab源码 1981期】