当前位置:网站首页>Blocking of concurrency control
Blocking of concurrency control
2022-07-05 21:59:00 【Short section senior】
What is blockade
Blockade is business T On a data object ( Such as table 、 Records, etc. ) Before the operation , Make a request to the system first , Lock it
After lock transaction T It has certain control over the data object , In the transaction T Before releasing its lock , Other transactions cannot update this data object .
Blocking is a very important technology to realize concurrency control
Basic blockade types
What kind of control a transaction has after locking a data object is determined by the type of blocking .
Basic blockade types
Exclusive lock (Exclusive Locks, Short for X lock )
Exclusive lock is also called write lock
If business T For data objects A add X lock , Only T Read and modify A, Nothing else can be done to A Add any type of lock , until T Release A The lock on the
Make sure other things are in T Release A The lock on can't be read or modified before A
Shared lock (Share Locks, Short for S lock )
Shared locks are also called read locks
If business T For data objects A add S lock , The transaction T You can read A But it can't be modified A, Other things can only be done to A Add S lock , Instead of X lock , until T Release A Upper S lock
Make sure other transactions are readable A, But in T Release A Upper S You can't do it before you lock it A Make any changes
Compatibility matrix of lock

Y=Yes, Compatible requests
N=No, Incompatible requests
In the compatibility matrix of locks :
The leftmost column represents transactions T1 The type of lock on the acquired data object , The horizontal line indicates that it is not locked .
The top line represents another transaction T2 Blocking request for the same data object .
T2 Whether the blocking request can be satisfied is used in the matrix Y and N Express
Y Presentation transaction T2 The blockade requirements and T1 Lock held , The blocking request can satisfy
N Express T2 Your blocking request is related to T1 Lock already held conflicts ,T2 's request was rejected
Welcome to join me for wechat exchange and discussion ( Please note csdn Add )
边栏推荐
- 怎么利用Tensorflow2进行猫狗分类识别
- A long's perception
- CRM creates its own custom report based on fetch
- [Yugong series] go teaching course 003-ide installation and basic use in July 2022
- ICMP 介绍
- Implementation technology of recovery
- 1.2 download and installation of the help software rstudio
- 【愚公系列】2022年7月 Go教学课程 003-IDE的安装和基本使用
- Bitbucket installation configuration
- Summary of data analysis steps
猜你喜欢

Efficiency difference between row first and column first traversal of mat data types in opencv

QML reported an error expected token ";", expected a qualified name ID

K210学习笔记(四) K210同时运行多个模型

The real situation of programmers

Some common processing problems of structural equation model Amos software

Implementation technology of recovery

A number of ventilator giants' products have been recalled recently, and the ventilator market is still in incremental competition

AD637使用笔记

华为快游戏调用登录接口失败,返回错误码 -1

Installation of VMware Workstation
随机推荐
力扣------经营摩天轮的最大利润
Emotional analysis of wechat chat records on Valentine's day based on Text Mining
Robot operation mechanism
Daily question brushing record (XIV)
Gcc9.5 offline installation
Reptile practice
MATLAB | App Designer·我用MATLAB制作了一款LATEX公式实时编辑器
Ethereum ETH的奖励机制
Drawing HSV color wheel with MATLAB
Recursive query of multi-level menu data
Yolov5 training custom data set (pycharm ultra detailed version)
KingbaseES V8R3集群维护案例之---在线添加备库管理节点
854. String BFS with similarity K
How to use tensorflow2 for cat and dog classification and recognition
阿里云有奖体验:用PolarDB-X搭建一个高可用系统
Bitbucket installation configuration
Implementation technology of recovery
Interview questions for basic software testing
装饰器学习01
MySQL连接断开报错MySQLdb._exceptions.OperationalError 4031, The client was disconnected by the server