issues
search
hhstore
/
blog
My Tech Blog: about Mojo / Rust / Golang / Python / Kotlin / Flutter / VueJS / Blockchain etc.
https://github.com/hhstore/blog/issues
294
stars
24
forks
source link
Distributed Transactions Manager
#382
Open
hhstore
opened
2 years ago
hhstore
commented
2 years ago
related:
✅ #170
✅ #79
✅ #195
✅ #56
hhstore
commented
2 years ago
分布式事务中间件:
https://www.cnblogs.com/chengxy-nds/p/14046856.html
https://zhuanlan.zhihu.com/p/183753774
http://icyfenix.cn/architect-perspective/general-architecture/transaction/distributed.html
https://juejin.cn/post/6844903647197806605
原理:
CAP 定理(Consistency、Availability、Partition Tolerance Theorem),也称为 Brewer 定理
ACID:
A:原子性(Atomicity)
C:一致性(Consistency)
I:隔离性(Isolation)
D:持久性(Durability)
方案:
✅ 乞丐方案: Redis
✅ 2PC(Two-phase commit protocol), 二阶段提交
✅ 3PC: 相比于 2PC, 在
参与者
中引入
超时
机制,并新增一个阶段使得
参与者
可以利用
此阶段
统一各自的状态。
✅ TCC 事务(Try - Confirm - Cancel)
https://dtm.pub/guide/e-tcc.html
✅ 消息事务: RocketMQ
社区项目:
go:
✅
https://github.com/dtm-labs/dtm
https://www.dtm.pub/
✅
https://github.com/seata/seata-go
https://seata.io/zh-cn/blog/seata-analysis-go-server.html
hhstore
commented
2 years ago
DTM:
https://www.dtm.pub/
https://github.com/dtm-labs/dtm
集成其他项目:
go-zero:
https://go-zero.dev/cn/docs/eco/distributed-transaction/
hhstore
commented
2 years ago
Seata:
https://github.com/seata/seata-go
XA 事务:
https://seata.io/zh-cn/blog/seata-xa-introduce.html
https://segmentfault.com/a/1190000039910621
hhstore
commented
2 years ago
1
hhstore
commented
2 years ago
1
related: