Java-RPC
RPC is Remote Procudure Call, a technique that is used in C-S architecture, which can be represented as the following graph.
- The client invokes the service as a local call.
- The client stub is responsible for assembling methods, parameters, etc. into a message that can be transmitted over the network and sending the message to the server.
- The server stub receives the message, decodes it, and calls the local service.
- The local service executes and returns the results to the server stub.
- The server stub packages the returned results into a message and sends it to the caller.
- The client stub receives the message and decodes it
- The client gets the final result