SOFA Weekly | Picks of the Week [6/10 - 6/14]

SOFA WEEKLY | weekly specials, weekly essence screening Q & A

Open source synchronization progress, interactive welcome message

640?wx_fmt=png

SOFAStack (Scalable Open Financial Architecture Stack) is a gold suit ant self-developed financial level distributed architecture, including the various components needed to build the original class cloud financial architecture students , including micro-services development framework, RPC framework, service registry, distributed regular tasks, limiting / blown framework, dynamic configuration push, distributed link tracking, metrics monitors measure, highly available distributed message queuing, distributed transaction framework, distributed database proxy layer and other components, but also out of temper in the financial scene best practices.

SOFAStack document:  https://www.sofastack.tech/

SOFAStack: https://github.com/sofastack


  Each week Recommended Reading   



  Reader Q & A refined week  


Welcome to leave a message to the public to ask questions or interact with our number in the group

We will focus on the problem by screening 

Form "SOFA WEEKLY" reply


1, @ Ku  question:

Will SOFARPC in Docker how publishing services, how to make the service outside of the container (an unusual night host) can have access to?

A: Sign up addresses is mapped address. Set com.alipay.sofa.rpc.virtual.host this property in application.properties. See:

https://www.sofastack.tech/sofa-rpc/docs/Application-RPC-Config


2、@蒲冬 提问:

关于 SOFAJRaft,leader 什么时候将日志应用于自己的状态机?我看 Raft 规范中,leader 应该是在接收到半数以上 follower 的应答之后才会应用到自身的状态机的。但在 SOFAJRaft 的代码中,我觉得 leader 是在LeaderStableClosure 中直接应用到自身状态机了,但是在 Replicator.onAppendEntriesReturned 中为什么又提交了一次,这个没懂。在代码中何处体现了 leader 是收到半数以上的 follower 应答才应用状态机的?

A:参见 BallotBox.commitAt,在这段代码里会检查每条日志的 Ballot 是否达到多数派 commit( Ballot#isGranted 方法),如果没有,就会终止查找。 找到最小已达到多数派 commit 日志 index 后(也就是 lastCommitedIndex),调用 FSMCaller#onCommitted 应用日志到状态机。


640?wx_fmt=png


另外一个问题,我看 Raft 中的数据都是存储在 LogManagerImpl 的 logsInMemory 中的,如果数据量大的时候,是否会出现内存溢出的情况。从 Raft 规范的角度看,一个新的成员加入时,leader 需要向这个新成员同步全部的数据。如果 leader 的数据量很大,那么这个同步时间是否会很长?从这个角度看,Raft 协议是否适合大量数据的一致性?

A:logsInMemory 是用来作为日志的内存缓存,加速日志的复制和应用,在应用到状态机后就会从内存里卸载。logsInMemory 保存的只是 commit 还没有 apply 的日志,并不是全部日志,日志都是写入 LogStorage 的。

也可以看看这几篇解析:

https://zhuanlan.zhihu.com/p/68052705

https://zhuanlan.zhihu.com/p/68031625


3、@孙靖皓 提问: 

使用Seata的时候,我把客户端都停了,只启动 Server,仍然会触发 RetryRollbacking,复现的话,还没找到规律。

A:因为这个分支没有被回滚掉,会默认进行无限重试,你需要删除 File 或者BD 中的表记录。


修改 server 下 store.mode=db 不起作用,是什么情况?

640?wx_fmt=png

A:启动命令加上--storeMode db


file.conf 里的 store.mode 修改本来也不会生效,是么?

A:启动参数指定了用启动参数的,没指定用 file.conf 的。


4、@程春根 提问:

我有10个微服务,那我要分10个组吗 ?

A:分组的含义就是映射到一套集群,所以你可以配一个分组也可以配置多个。如果你其他的微服务有独立发起事务可以配置多个,如果只是作为服务调用方参与事务那么没必要配置多个。


不知道分组的目的是什么?那不管什么情况我始终就一个分组有没问题?

A:没问题,分组是用于资源的逻辑隔离,多租户的概念。


没问题就好。是不是一个事务中所有的微服务都必须是同一组才行?

A:没有这个要求的。但是不同的分组需要映射到同一个集群上。


你说的集群是指 TC 集群吗?现在 TC 如何集群,我看配置里都是 default。

A:那个名字可以自己取,如果用文件形式你可以写多个地址列表,多台 server 以 DB 方式存储通过 DB 共享数据。如果用注册中心就可以自己发现,注册的时候定义了集群名。


   每周 SOFA 进展  


本周发布详情如下:

1、发布 SOFARPC v5.5.6 , 主要变更如下:

i. 修复 SOFARegistry 场景下地址为空场景下的可能问题

ii. 支持 Ark 隔离, 发布服务时,注册服务类加载器

详细参考发布报告:

https://github.com/alipay/sofa-rpc/releases/tag/v5.5.6


2、发布 SOFABoot v3.1.5 , 主要变更如下:

i. 修复 Banner 字体打印问题.

ii. 升级 SOFARPC Starter 版本至 6.0.3

详细参考发布报告:

https://github.com/sofastack/sofa-boot/releases/tag/v3.1.5


  与 SOFA 相遇  


640?wx_fmt=png

GIAC(GLOBAL INTERNET ARCHITECTURE CONFERENCE)是面向架构师、技术负责人及高端技术从业人员的年度技术架构大会,是中国地区规模最大的技术会议之一。 

本次,蚂蚁金服受邀带来主题分享,点击“阅读原文”即可了解更多,欢迎与我们探讨


时间:6 月 23 日

地点:中国 · 深圳


主题:《蚂蚁金服 Service Mesh 落地实践与挑战》

讲师:蚂蚁金服技术专家 石建伟(花名:卓与)

你将收获:

1. Service Mesh 落地带来的业务价值 

2. 传统 SOA 应用如何向 Service Mesh 方向演进 

3. 了解我们演进过程中的各种坑如何填补

主题详细介绍:

http://giac.msup.com.cn/Giac/schedule/course?id=13816


Theme: "Ant gold suit large-scale distributed transaction practices and introduce open source"

Instructor: Ants gold dress technical experts Sen (nickname: Shaohui)

You will gain:

1. Background and rationale distributed transaction
2. open source framework for distributed transaction Seata explain
3. Distributed Transaction practical experience in the production of ants

Theme Details:

http://giac.msup.com.cn/Giac/lecturer/teacher?id=7133


640?wx_fmt=png

Guess you like

Origin blog.csdn.net/SOFAStack/article/details/92032558