A Remote Procedure Call appears to the user like a call to a function on the local machine.
RPC concept is similar to conventional programming
Procedure calling has well understood semantics
RPC simplifies access to remote systems
Function parameters are marshalled into a communications packet and sent to the server which calls the appropriate function with the data provided.
Exception handling - what does the communication stub do if the first effort to send a msg fails?
no retry RPC may not work
at-least-once Keep sending until it gets there idempotent functions
at-most-once retry but server must filter repeats
Binding of server location
transparency - it would be nice if an RPC looked just like a local function call
portability - allow the application to be used on different systems
load balancing - select server with lowest utilization
failure recovery - select a different server if original fails
write server name in code
put server name in header file
specify to the linker
all RPC applications call an initialization function
put the server address in the function call
file of server addresses
ask a human
broadcast request for a server
Asynchronous RPC without reply - stub returns to caller after sending message
Asynchronous RPC with reply
callbacks - client accepts call from the server
promises - each RPC generates a promise. A promise identifies the RPC reply to be provided later. A promise can be ready or blocked. The client can inspect a promise without blocking and can retrieve the results.
X- windows uses Asynchronous RPC
main computer is the client
terminal is the server