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

什么是RPC?为什么要用RPC? #53

Open
storyflow opened this issue Sep 29, 2020 · 1 comment
Open

什么是RPC?为什么要用RPC? #53

storyflow opened this issue Sep 29, 2020 · 1 comment

Comments

@storyflow
Copy link
Owner

本地过程调用

RPC就是要像调用本地的函数一样去调远程函数

@storyflow
Copy link
Owner Author

RPC与REST有什么区别?

1、REST API 和 RPC 都是在 Server端 把一个个函数封装成接口暴露出去,以供 Client端 调用,不过 REST API 是基于 HTTP协议 的,REST致力于通过http协议中的POST/GET/PUT/DELETE等方法和一个可读性强的URL来提供一个http请求。而 RPC 则可以不基于 HTTP协议

2、RPC 可以获得更好的性能(省去了 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

No branches or pull requests

1 participant