关于1,你的理解是对的,没有任何必要

发自我的 iPhone

在 2023年8月21日,14:02,大胖子、 <curryco...@qq.com.invalid> 写道:


Dubbo开发项目组成员们,你们好!

目前我司在项目中使用到了Dubbo,我对于目前的项目架构产生了一些疑问,想得到你们官方人员的解答,非常感谢。

我司的项目架构,是将单个服务的controller和service分开成了两个服务,然后controller层通过Dubbo来远程RPC调用service中的服务。对于此设计,我有一些疑问:
1. 这样设计有必要吗?Dubbo作为一个远程RPC调用框架,想要解决的应该是不同服务之前的调用问题,而在单个服务间通过这种方式调用,是否完全是多此一举?
2. 通过远程RPC调用,怎么也会产生额外的网络开销,在存在网络波动的情况下,就会出现调用失败的问题,但这种情况,完全是可以通过本地的注入来避免的。
3. 
将一个服务,拆分成web和service服务,不就额外的增加了服务器资源使用吗?而且service服务提供的接口,可以说99%都是没有其他服务来调用的,把这些数据注册到注册中心,是否也完全属于是浪费资源?

以上这些是我认为目前架构中我不理解的地方,因为我之前使用的比较多的是SpringCloud,所以我不知道这种架构是不是Dubbo官方所推荐的方式?
希望能够得到官方的回复,如果我的描述有不清楚的地方,也请告诉我,我会尽可能的表达清楚,感谢🙏!

(示例的架构代码已上传到附件)

Dear members of the Dubbo development team,

Greetings! Currently, our company is using Dubbo in our project. I have some 
questions regarding our current project architecture and would greatly 
appreciate official insights from your team.

In our project architecture, we have separated the controller and service 
layers of a single service into two independent services. The controller layer 
uses Dubbo for remote RPC calls to the services. I have some concerns about 
this design:

1. Is this design necessary? Dubbo being a remote RPC framework should address 
inter-service communication. However, using this approach within a single 
service seems redundant. Is it an overcomplication?
2. Remote RPC calls do introduce additional network overhead. Network 
instability can lead to call failures. However, this could be avoided using 
local injection in cases of network instability.
3. By splitting a service into web and service components, doesn't it lead to 
extra server resource consumption? Moreover, most interfaces provided by the 
service are rarely called by other services. Registering these in the service 
registry, isn't this resource wastage?

These are the aspects of the current architecture that I find puzzling. As I 
have previously worked more with Spring Cloud, I'm unsure if this architecture 
aligns with Dubbo's official recommendations.

I hope to receive an official response. If my description is unclear in any 
way, please let me know. I'll do my best to provide a clear understanding. 
Thank you 🙏!

(The example architecture code has been uploaded as an attachment.)
________________________________
<https://wx.mail.qq.com/home/index?t=readmail_businesscard_midpage&nocheck=true&name=Zhao&icon=http%3A%2F%2Fp.qlogo.cn%2Fqqmail_head%2F2HHcAN85a8NAOqOzDscIXSScutL5tIQvaAtNxbsy83Vr0F0aHqWbzDAHTGOLwCmV%2F160&mail=currycooky%40qq.com&code=>
[http://p.qlogo.cn/qqmail_head/2HHcAN85a8NAOqOzDscIXSScutL5tIQvaAtNxbsy83Vr0F0aHqWbzDAHTGOLwCmV/160]
Zhao
curryco...@qq.com

Reply via email to