Remote Procedure Calls Flashcards
1
Q
(7 steps)
What are the steps involved in Remote Procedure Calls (RPC)?
A
- The calling system creates an RPC call and the client RPC service:
- Creates a unique ID for the call
- Marshals the argument into some suitable format
- Sets a timer
- Data is passed as a message through the lower levels
- The server RPC service:
- Unmarshals the arguments
- Makes a note of the ID for this RPC call
- The called system calls and executes the required method
- The server RPC service:
- Marshals the return arguments, ready for transport
- Sets a timer
- The client RPC service:
- Unmarshals the return arguments
- Disables the client RPC service timer
- Sends an acknowledgement to the server RPC service that the RPC with the specified ID has arrived safely
- The server RPC service timer is disabled
2
Q
(5 answers)
Describe how RPC timers work and how they provide robustness.
A
- The timers will expire if there is a problem
- Failure of the client is not noticed until no acknowledgement arrives, meaning it may not be possible to undo certain state changes at the server side
- Failure of the server will always be noticed due to the first timer expiring and when this happens, the client may decide to repeat the call using the same ID
- If the called system detects a repeated RPC call, it can just resend the message
- If the called system does not detect a repeated RPC call, this may result in changes to the data being made twice