Remote Procedure Calls (RPC) Architecture with its Protocol, Types, and Examples!!

DigitalThinkerHelp
5 min readJul 12, 2022

Definition: Remote Procedure Call (RPC) is a very useful technique for making distributed and client-server based applications. RPC works as protocol that one program can obtain to request a service from program situated in other computer network without knowing any information of network. Procedure call is also called the “Function Call” or “Subroutine Call“. Remote Procedure Call is also used to make call another process on the remote system such as local system.

Remote Procedure Call In Operating System (OS)

Remote Procedure Call delivers the high level communications paradigm that is implemented in the different types of operating system.

It gets to presume the existing low level transport protocol, like as Transmission Control Protocol/Internet Protocol (TCP/IP) or User Datagram Protocol (UDP), and these protocols help to carry all massages in between communicating programs. Often, Remote Procedure Call is introduced for logical client-to-server communications system that is supported to network applications in real time embedded systems.

Architecture of RPC (Remote Procedure Calls)

RPC architecture has major five elements; like as –

  • Client
  • Client Stub
  • RPC Runtime
  • Server Stub
  • Server

How Does Work RPC

Sequence steps are performed while getting RPC process:

  1. Client machine helps to execute client stub and instance of RPC run time which are provided by client.
  2. Client begins the client stub process that is passed in usual way, then client stub gets to save client’s address space, and finally it sends toward to server
  3. In this step, RPC Runtime handles the all transmission of messages in between all client-server networks, and it also able to do other jobs like as acknowledgment, routing, retransmission and encryption.
  4. After getting done server procedure, it sends back to server stub that packs return all values into message form, and then finally server stub fires a message back to transport layer.
  5. In this stage, transport layer fires back the resultant message to client transport layer, and finally moves back a message to client stub.
  6. In this step, client stub gets to unpack return parameters in the resultant packet, and finally execution process moves back to the caller.

Types of RPC (Remote Procedure Calls)

There are five different types of Remote Procedure Calls; below explain each one

Synchronous: In Synchronous operation, the client try to make a call and does not able to regular until server returns the reply.

Non-blocking: In this operation, the client tries to make a call and continues along with its own processing, but server does not able to reply.

Batching RPC: This RPC allows to get queues, individual RPC requests, in the transmission buffer, over the client-edge, and then finally push them over the network in single batch to the server

Batching RPC Operations

  • Decrease overhead in sending request over the network.
  • Allowing to reliable transmission protocol
  • It is more helpful for those applications which are required less call rates.

Broadcast RPC: It allows to RPC clients broadcast facility, so they can broadcast all messages to several servers and then obtain entire consequent replies.

Broadcast RPC Operations

  • It allows to declare that client’s request messages have to be broadcast.
  • Users are able to specify the broadcast ports.
  • It allows to minimize the load over the physical network.

Callback RPC: In callback RPC, all clients are able to make non-blocking client/server call, and then server signal done by calling a procedure associated along with the clients.

Callback RPC Operations

  • Handle callback deadlocks
  • Callback makes the client process wait
  • Provide services server along with clients handle.

Examples of RPC (Remote Procedure Calls)

There are various examples of Remote Procedure Calls (RPC); below mention all.

Remote File Access: Earliest, RPC was used to remote file and database access. Remote Procedure Calls was running in Valet-Plus VME-based test system, over Ethernet for getting to access all files on the mainframes computers and minicomputers.

Remote Software Task Management Load/Start/Control: In this stage, RPC permits the co-coordinating computer to execute various management functions required to configure and start the software in the enlarge data acquisition system.

Remote Graphics: In this case, active monitoring program gets to make call GKS standard graphics primitives, which are executed on a remote workstation.

Other Examples of RPCs

  • Remote monitoring program control
  • Remote FASTBUS access
  • Remote error logging
  • Remote terminal interaction with processors in VMEbus
  • Submission of operating system commands from embedded microprocessors

Advantages of RPC (Remote Procedure Call)

There are various benefits of Remote Procedure Call (RPC); such as –

  • RPC helps to clients for making communication with different types of servers through use of procedure calls in high-level languages.
  • It can support to thread-oriented models and process-oriented.
  • It helps to get invisibility of their internal message-passing mechanism from the user.
  • It is implemented in the local environment as well as distributed environment.
  • RPC is able to rewrite and redevelop code with minimum efforts.
  • RPC supports to several protocol layers for growing performance.
  • Remote Procedure Call offers the “Abstraction“. For instance, it can pass messages of the network communication remains hidden from the users.
  • It offers a well defined interface.
  • It is able to make communication in between process on the similar otherwise dissimilar machines.
  • Simple call syntax and Offers known semantics
  • Processes cannot share address space
  • Parameters can be passed with using of their values.
  • RPC can execute only within the environment of server process.

Disadvantages of RPC (Remote Procedure Call)

  • Remote Procedure Call systems are not comfortable to transfer enlarge amounts of data.
  • RPC is not allowed to pass Parameters by pointer.
  • RPC involves communication system, another machine and another process, so it is vulnerable to get failure.
  • RPC has not any uniform standard, so it can be used in different kinds of ways.
  • RPC doesn’t provide any flexibility while using of hardware architecture.
  • Due to remote procedure call, process’s cost is enhanced.

--

--

DigitalThinkerHelp

Hi i am Er. R S Banger. I have done B Tech as well as M Tech in CSE and doing Research on Digital Marketing.