About Remote Procedure Call
Microsoft remote procedure call (RPC) represents the convergence of three powerful programming models: the familiar model of developing C applications by writing procedures and libraries; the model that uses powerful computers as network servers to perform specific tasks for their clients; and the client/server model, in which the client usually manages the user interface while the server handles data storage, queries, and manipulation. When you write a client/server application, you must provide the layer of code that manages network communication. RPC tools provide this layer for you.
As a tool for creating distributed applications, RPC provides the following benefits:
-
A familiar and popular programming model. You can easily turn functions into remote procedures, which simplifies the development and test cycles. Also, the Microsoft implementation is compatible with both client and server applications.
-
A method of hiding many details of the network interface from the developer. You don't need to understand specific network functions or low-level network protocols to implement powerful distributed applications.
-
A solution to the data-translation problems that occur in heterogeneous networks; individual applications can ignore this problem.
-
A scalable approach. As a network grows, applications can be distributed to more than one computer on the network.
When developing client/server applications using RPC, you must perform the following tasks:
-
Specify the protocol sequences that the server application will use to communicate with clients.
-
Enter the server into a listening mode for client requests.
-
Have the client application define the function interfaces using the Interface Definition Language (IDL) and compile the IDL file using the MIDL compiler.
-
Have the client application use automatic binding or application-managed binding (manage binding handles, and so on).
For more information about Microsoft RPC, see the "Internet, Networking, and Distributed Services" section of the Microsoft Platform SDK.