RPC和RMI的区别(Difference Between RPC and RMI)
RPC和RMI的区别(Difference Between RPC and RMI)
RPC (Remote Procedure Call) and RMI (Remote Method Invocation) are two mechanisms that allow the user to invoke or call processes that will run on a different computer from the one the user is using. The main difference between the two is the approach or paradigm used. RMI uses an object oriented paradigm where the user needs to know the object and the method of the object he needs to invoke. In comparison, RPC isn’t object oriented and doesn’t deal with objects. Rather, it calls specific subroutines that are already established.
RPC(远程过程调用)和RMI(远程方法调用)是两种可以让用户从一台电脑调用不同电脑上面的方法的的机制(也可以称作规范、协议)。两者的主要不同是他们的使用方式或者称作范式,RMI使用面向对象的范式,也就是用户需要知道他调用的对象和对象中的方法;RPC不是面向对象也不能处理对象,而是调用具体的子程序。
RPC is a relatively old protocol that is based on the C language, thus inheriting its paradigm. With RPC, you get a procedure call that looks pretty much like a local call. RPC handles the complexities involved with passing the call from the local to the remote computer. RMI does the very same thing; handling the complexities of passing along the invocation from the local to the remote computer. But instead of passing a procedural call, RMI passes a reference to the object and the method that is being called. RMI was developed by Java and uses its virtual machine. Its use is therefore exclusive to Java applications for calling methods on remote computers.
RPC是一个基于C语言的相对较旧的协议,因此也就继承了C语言的范式,使用RPC,你可以像调用一个本地方法一样调用远程的方法,由RPC处理调用过程的复杂操作,RMI的功能和RPC基本一样。但是和RPC只传输一个过程调用不同,RMI需要传输对象的引用以及调用的方法。RMI是用Java开发的,运行在Java虚拟机上,因此它的用途是调用远程计算机上的java应用程序。
In the end, RPC and RMI are just two means of achieving the same exact thing. It all comes down to what language you are using and which paradigm you are used to. Using the object oriented RMI is the better approach between the two, especially with larger programs as it provides a cleaner code that is easier to track down once something goes wrong. Use of RPC is still widely accepted, especially when any of the alternative remote procedural protocols are not an option.
最后,RPC和RMI只是处理同一个问题的不同方式,这一切都归结于你所使用的语言和你所使用的范式。使用面向对象的RMI是两者之间的更好的方法,特别是大型程序,使用RMI代码更简洁,更容易追踪bug。RPC目前依然是被广泛接受的,尤其是当无法选择任何的可替代的远程程序协议时候。
Summary:
1.RMI is object oriented while RPC isn’t2.RPC is C bases while RMI is Java only3.RMI invokes methods while RPC invokes functions4.RPC is antiquated while RMI is the future
总结:
1、RMI是面向对象的,而RPC不是
2、RPC是基于C语言的,而RMI是仅仅基于Java的
3、RMI调用方法,而RPC调用函数
4、RPC是过时的,而RMI是未来
原文地址: Difference Between RPC and RMI | Difference Between | RPC vs RMI http://www.differencebetween.net/technology/protocols-formats/difference-between-rpc-and-rmi/#ixzz47OPXuhEv
博客
RPC和RMI的区别(Difference Between RPC and RMI)的更多相关文章
- SOA,Webservice,SOAP,REST,RPC,RMI的区别与联系
SOA,Webservice,SOAP,REST,RPC,RMI的区别与联系 SOA面向服务的软件架构(Service Oriented Architecture) 是一种计算机软件的设计模式,主要应 ...
- RPC与RMI的区别
分布式项目按照以下发展经历了以下技术: CORBA: RMI:基于远程接口的调用 RMI-RROP:这是RMI与CORBA的结合,用在了EJB技术上,EJB留给世界上是优秀的理论和糟糕的架构. WEB ...
- RPC框架-RMI、RPC和CORBA的区别
关键词:RMI RPC CORBA简 介:本篇文章重点阐述RMI,附带介绍RPC和CORBA Java远程方法调用(Java RMI)是一组实现了远程方法调用(rmi)的API. java RMI是远 ...
- RPC的解释以及RPC和Restful、RPC和RMI的区别
如何科学的解释RPC 说起RPC,就不能不提到分布式,这个促使RPC诞生的领域. 假设你有一个计算器接口,Calculator,以及它的实现类CalculatorImpl,那么在系统还是单体应用时,你 ...
- RPC和WebService的区别
最近分析的这个系统,逻辑架构中有一层是RPC interface.之前对RPC不熟悉,就上网搜索了一下资料,在此总结一下: RPC是Remote Procedure Calling,远程过程调用的缩写 ...
- RPC接口测试(二) RPC 与HTTP的区别
RPC 与HTTP的相同点 两种风格的API区别,总结一下其实非常简单: 1,RPC面向过程,只发送 GET 和 POST 请求.GET用来查询信息,其他情况下一律用POST.请求参数是动词,直接描述 ...
- Linux中LPC、RPC、IPC的区别
其实这玩意儿就是纸老虎,将英文缩写翻译为中文就明白一半了. IPC:(Inter Process Communication )跨进程通信 这个概念泛指进程之间任何形式的通信行为,是个可以拿来到处套的 ...
- RPC接口测试(一)什么是 RPC 框架
什么是 RPC 框架 RPC 框架----- 远程过程调用协议RPC(Remote Procedure Call Protocol)-----允许像调用本地服务一样调用远程服务. RPC是指远程过程调 ...
- RPC服务治理框架(一)RPC技术
一.RPC是什么 remote procedure call:远程过程调用 过程就是程序,像调用本地方法一样调用远程的过程 RPC采用Client-Server结构,通过request-respons ...
随机推荐
- Python日志输出格式和时间格式
formatter = logging.Formatter("%(asctime)s %(levelname)s %(message)s","%Y%b%d-%H:%M:% ...
- iOS发展- backBarButtonItem 颜色/文字修改
iOS7之后. 默认返回button字体颜色为蓝色, 在父母的陈列柜VC(老界面)的title 假设做出改变, 通过下面的方法可以: 1. 更改字体颜色 (1) 在plist里面, 加View con ...
- RH033读书笔记(14)-Lab 15 Switching Users and Setting a Umask
Lab 15 Switching Users and Setting a Umask Goal: Become familiar with the use of several essential c ...
- 最少拦截系统(杭电1257)(DP)+(贪心)
最少拦截系统 Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) Total Sub ...
- 使用Bootstrap 他写道网站
新发现vdceye有些难看的网站,为了找到一个bootstrap工具,我一次又一次地写信给网站 这个工具是很容易使用 http://vdceye.com/ 版权声明:本文博客原创文章,博客,未经同意, ...
- maven插件的生命周期的详细说明(两)
插件配置 定义解释:插件目标 当我们了解了maven插件之后.我们发现假设为每个功能编写一个独立的插件显然是不可取的,由于这些任务背后有非常多能够复用的代码.因此,把这些功能聚集在一个插件里,每个功能 ...
- .net RPC框架选型(一)
近期开始研究分布式架构,会涉及到一个最核心的组件:RPC(Remote Procedure Call Protocol).这个东西的稳定性与性能,直接决定了分布式架构系统的好坏.RPC技术,我们的产品 ...
- UML部署图和图九组件图
前言 UML大部分描写叙述了逻辑和设计方面的信息.实现图用来描写叙述实现方面的信息.实现图包含部署图和构件图. 构件图 1. 概念 构件图从软件架构的角度来描写叙述一个系统的 ...
- 漫话Unity3D(三)
八.预制(Prefab) 这个单独提出来,是由于它太经常使用了.也是Unity 的核心要素之中的一个.原本Unity中的一个物体是你拖拽一个模型到场景中,或者创建一个几何体,或者灯光地形等,然后设置这 ...
- 关于 cookie 使用中遇到的问题
前段时间在一个项目中涉及到cookie的存取,于是打算封装一个 cookie 的CRUD .按理来说,这本身是一个很简单的问题,不注意的话简单的问题也有大坑. /** * Set or get coo ...