Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

draft PR #7

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

draft PR #7

wants to merge 4 commits into from

Conversation

FreddyGao
Copy link

enhancement for #1

设计方案
首先,根据我看代码的过程,在咱们这项目中的RPC调用依赖于 internal/rpc 包中所定义的mdsClinet, 这个mdsClient 的初始化以及方法调用都依赖于curve-go-rpc 这个包,我们这个项目的目的是去除这个包的依赖,并且改为HTTP的通信方式,我做了如下几步操作
1: 同样在internal 下构建http包,之后所有上层关于RPC的方法调用全部都是用这个包中重新开发的方法调用目录如下
http
——badeHttp
——common
——curvebs
该模块仿照curve-go-rpc的结构构建而成,从而提供之前rpc包中的所有http版本方法
2: 关于HTTP的调用,在baseHTTP/http中定义,里面最重要的是定义了sendHTTP方法(原来是sendRPC),之后所有方法与Cluster的通信均通过其通信
3: 改动最大的部分,是将namespace中和topology中的所用方法都改成了HTTP版本例如ListPhysicalPool方法改版为
ListPhysicalPool_http。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant