Remote Procedure Call RPC Back born of Network Programming

1 / 13
About This Presentation
Title:

Remote Procedure Call RPC Back born of Network Programming

Description:

A remote procedure is uniquely identified by the triple: (program number, ... What happens when the server crashes while executing a service procedure? ... –

Number of Views:58
Avg rating:3.0/5.0
Slides: 14
Provided by: Micro270
Category:

less

Transcript and Presenter's Notes

Title: Remote Procedure Call RPC Back born of Network Programming


1
Remote Procedure Call (RPC)Back born of Network
Programming
2
Objectives
  • What is RPC?
  • What are the working principles of RPC?
  • What is RPC calling Mechanism?
  • What are steps for RPC application development?
  • What are the consideration of RPC protocol?
  • What is the need of XDR filter?
  • RPC LIB
  • What is state and why it is important?
  • High-level RPC applications

3
What is RPC?
  • RPC is a powerful technique for constructing
    distributed client server applications.
  • The executing procedure may not exist in the same
    address space as the calling procedure.
  • By using RPC, programmers of distributed
    applications avoid the details of interface with
    the network.
  • TCP and UDP supports
  • ONC RPCGEN protocol compiler

4
Remote versus local procedure calling
5
RPC Makes Interprocess Communication Less Painfull
  • IPC is an essential part of the clientserver
    model.
  • Machines portability
  • Socket problem
  • ONC RPC and DEC RPC.

6
How RPC Works
7
How RPC Works (cont.)
8
Remote Procedure Calling Mechanism
  • A remote procedure is uniquely identified by the
    triple (program number, version number,
    procedure number).
  • To develop an RPC application the following steps
    are needed
  • Specify the protocol for client server
    communication
  • Develop the client program
  • Develop the server program

9
Defining the Protocol
  • For the protocol you must identify the name of
    the service procedures, and data types of
    parameters and return arguments.
  • The protocol compiler reads a definition and
    automatically generates client and server stubs.
  • Rpcgen uses its own language (RPC language or
    RPCL) which looks very similar to preprocessor
    directives.
  • rpcgen rpcprog.x
  • This will generate possibly four files
  • rpcprog_clnt.c ? the client stub
  • rpcprog_svc.c ? the server stub
  • rpcprog_xdr.c ? If necessary XDR (external data
    representation) filters
  • rpcprog.h ? the header file needed for any XDR
    filters.

10
XDR filter
  • The external data representation (XDR) is a data
    abstraction needed for machine independent
    communication. The client and server need not be
    machines of the same type.

11
RPCGEN
12
What is State and why it is important?
  • what happens when they cannot communicate with
    each other?
  • What happens when the server crashes while
    executing a service procedure? What does the
    client do? The response depends upon whether a
    server is stateless or stateful.
  • A stateless server does not maintain any
    information or state about the clients. Stateful
    servers accumulate client information for remote
    procedure calls and require it to function
    properly

13
RPC LIB
Write a Comment
User Comments (0)
About PowerShow.com