RPC Implementation

Remote  Procedure  Call
( RPC)  Implementation
·         An RPC is analogous to a function call. Like a function call, when an RPC is made, the calling arguments are passed to the remote procedure and the caller waits for a response to be returned from the remote procedure.
·          Figure 1 shows the flow of activity that takes place during an RPC call between two networked systems.
·         The client makes a procedure call that sends a request to the server and waits. The thread is blocked from processing until either a reply is received, or it times out.
·          When the request arrives, the server calls a dispatch routine that performs the requested service, and sends the reply to the client.
·          After the RPC call is completed, the client program continues. RPC specifically supports network applications.
·         The client calls a local procedure, called the client stub. To the client process, this appears to be the actual procedure, because it is a regular local procedure.
·          It just does something different since the real procedure is on the server. The client stub packages the parameters to the remote procedure (this may involve converting them to a standard format) and builds one or more network messages.
·         The packaging of arguments into a network message is called marshaling and requires serializing all the data elements into a flat array-of-bytes format.
·         Network messages are sent by the client stub to the remote system (via a system call to the local kernel using sockets interfaces).
·         Network messages are transferred by the kernel to the remote system via some protocol (either connectionless or connection-oriented).
·         A server stub, sometimes called the skeleton, receives the messages on the server.
·         The server stub calls the server function (which, to the client, is the remote procedure), passing it the arguments that it received from the client.
·         When the server function is finished, it returns to the server stub with its return values.
·         The server stub converts the return values, if necessary, and marshals them into one or more network messages to send to the client stub.
·         Messages get sent back across the network to the client stub.
·         The client stub reads the messages from the local kernel.
·         The client stub then returns the results to the client function, converting them from the network representation to a local one if necessary.

                                         Figure 1.  Remote Procedure Calling Mechanism Implemetation

                                               Fig (2):-RPC  Procedure

 More topics from Distributed System to read:


EasyExamNotes.com covered following topics in these notes.
Python Programming ↓ 👆
Java Programming ↓ 👆
JAVA EasyExamNotes.com covered following topics in these notes.
JAVA Programs
Principles of Programming Languages ↓ 👆
Principles of Programming Languages
EasyExamNotes.com covered following topics in these notes.

Previous years solved papers:
A list of Video lectures References:
  1. Sebesta,”Concept of programming Language”, Pearson Edu 
  2. Louden, “Programming Languages: Principles & Practices” , Cengage Learning 
  3. Tucker, “Programming Languages: Principles and paradigms “, Tata McGraw –Hill. 
  4. E Horowitz, "Programming Languages", 2nd Edition, Addison Wesley

    Computer Organization and Architecture ↓ 👆

    Computer Organization and Architecture 

    EasyExamNotes.com covered following topics in these notes.

    1. Structure of desktop computers
    2. Logic gates
    3. Register organization
    4. Bus structure
    5. Addressing modes
    6. Register transfer language
    7. Direct mapping numericals
    8. Register in Assembly Language Programming
    9. Arrays in Assembly Language Programming


    1. William stalling ,“Computer Architecture and Organization” PHI
    2. Morris Mano , “Computer System Organization ”PHI

    Computer Network ↓ 👆
    Computer Network

    EasyExamNotes.com covered following topics in these notes.
    1. Data Link Layer
    2. Framing
    3. Byte count framing method
    4. Flag bytes with byte stuffing framing method
    5. Flag bits with bit stuffing framing method
    6. Physical layer coding violations framing method
    7. Error control in data link layer
    8. Stop and Wait scheme
    9. Sliding Window Protocol
    10. One bit sliding window protocol
    11. A protocol Using Go-Back-N
    12. Selective repeat protocol
    13. Application layer
    1. Andrew S. Tanenbaum, David J. Wetherall, “Computer Networks” Pearson Education.
    2. Douglas E Comer, “Internetworking with TCP/IP Principles, Protocols, And Architecture",Pearson Education
    3. KavehPahlavan, Prashant Krishnamurthy, “Networking Fundamentals”, Wiley Publication.
    4. Ying-Dar Lin, Ren-Hung Hwang, Fred Baker, “Computer Networks: An Open Source Approach”, McGraw Hill.