marsishandsome / marsishandsome.github.io

Build a Jekyll blog in minutes, without touching the command line.
MIT License
1 stars 2 forks source link

Multi Version Concurrency Control – Mars的笔记 – Software Developer@PingCAP #16

Open marsishandsome opened 5 years ago

marsishandsome commented 5 years ago

https://marsishandsome.github.io/2019/06/Multi_Version_Concurrency_Control

事务冲突类型 两个事务并发,什么情况下会冲突?

vinllen commented 3 years ago

关于MVTO请教一个问题,写的时候锁定txn-id,直到commit后才会清掉txn-id,而读是会判断txn-id为0才会读取,这样如何进行读写的并发?比如A事务在write未commit的时候,B事务读取A事务修改之前的版本,read-committed隔离级别。 从论文中的阐述看,只有Bx+1的txn-id才会被置为txn-id,而Bx的txn-id是没有被置位的。 image 理论上是应该加锁的,这样的话是不存在写读冲突(write-too-late),毕竟写的时候,读锁加不上