Java-Interview-Advanced/docs/distributed-system/tcc-high-concurrence.md

24 lines
1013 B
Markdown
Executable File
Raw Permalink Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

TCC框架bytetccseata
seata-server
bytetcc大家就是基于mysql里面创建一些表基于表中的数据进行状态的更新
核心链路中的各个服务都需要跟TC这个角色进行频繁的网络通信频繁的网络通信其实就会带来性能的开销本来一次请求不引入分布式事务只需要100ms此时引入了分布式事务之后可能需要耗费200ms
网络请求可能还挺耗时的上报一些分支事务的状态给TCseata-server选择基于哪种存储来放这些分布式事务日志或者状态的file磁盘文件MySQL数据库来存放对应的一些状态
高并发场景下会不会有问题seata-server你也需要支持扩容也需要部署多台机器用一个数据库来存放分布式事务的日志和状态的话假设并发量每秒上万分库分表对TC背后的数据库也会有同样的压力
这个时候对TC背后的db也得进行分库分表抗更高的并发压力