Java architectures #1 – RMI

Java Remote Method Invocation (RMI)

RMI was Java’s first native solution for distributed computing, RMI API performs remote method invocation on objects, in a similar fashion to RPC.

It operates on a Client/Server architecture, where remote objects can be invoked from another JVM, remote objects are referenced in a RMI Registry.

Clients lookup services in the Registry and retrieves a stub that allows it to invoke methods in the remote object.

Java RMI architecture. 1. the server registers the remote object. 2. the client looks up the stub in the registry. 3. the client requests the stubs class file. 4. the client invokes methods on the remote object. The remote object and registry have to reside on the same machine  [1]

Java RMI was part of Sund JDK 1.1 and a prior release RMI-IIOP included support for CORBA (Common Object Request Broker Architecture).

Although RMI is still supported it’s a limited solutions, used mostly within Java application, it also doesn’t support authorization off the shelf.

[1] https://www.researchgate.net/publication/303854455_P2P-RMI_Transparent_Distribution_of_Remote_Java_Objects

[2] https://en.wikipedia.org/wiki/Java_remote_method_invocation

[3] Enterprise Java Programming with IBM WebSphere, 2003