0

I am studying a notes about RPC vs RMI but I understood not much of it. So asking here.

RPC supports procedural programming paradigms this is C based while RMI supports object oriented paradigms so is java based.

I understand this.

The parameters passed to Remote procedures in RPC are the ordinary data structure. But RMI transmits objects as a parameter to the remote method.

What does this mean? Can you explain this based on RMI architecture?(the first figure is RPC and second figure is RMI architecture.)

https://i.stack.imgur.com/ejH1d.jpg

RPC can be considered as the older version of RMI a nd it is used in the programming languages that support procedural programming and can only use pass by value method. On the other hand RMI facility is devised based on modern programming approach which could use pass by value or reference. Another advantage of RMI is that paramters passed by reference can be changed

I understand this.

RPC protocols generates more overhead than RMI.

Like how? Can you show with an example?

The paramters passed in RPC must be "in=out" which means that the value passed to the procdeure and the output value must have the same datatype. In contrast, there is no compulsion of passing "in=out" paramters in RMI.

I don't understand this. Can you explain with an example.

In RPC, reference could not be probably because the two processes have the distinct address space, but it is possible in case of RMI.

I don't understand this either. Can you explain with an example

  • I don't want to sound imprecise but the two terms are basically refering to the same, very much dated technology, replaced by RESTful web services and GraphQL. – Janez Kuhar Aug 09 '21 at 07:23
  • They might be outdated but still used in academics to teach. –  Aug 09 '21 at 07:48
  • @JanezKuhar No they do not refer to the same technology, and you'd be surprised how much of both is still in use and still being written. J2EE is based on RMI for example. – user207421 Aug 09 '21 at 07:56

0 Answers0