1/16
Looks like no tags are added yet.
Name | Mastery | Learn | Test | Matching | Spaced | Call with Kai |
|---|
No analytics yet
Send a link to your students to track their progress
What does RPC do?
Your code calls a function that looks local, but the actual execution happens on a different server across a network.
What is the goal of RPC?
To make remote requests look and feel exactly like local method calls.
You don't have to worry about the complexities of HTTP verbs (GET, POST) or manual URL routing like you do with REST.
How does RPC work? (Step 1)
The Client Stub:
Your application calls a local "stub" (a proxy). This stub marshals your data
How does RPC work? (Step 2)
The Transport:
The message is sent over the network (often using protocols like TCP or HTTP/2) to the remote server.
How does RPC work? (Step 3)
The Server Stub:
The server receives the message, unmarshals the data and calls the actual function sitting on the server's hardware.
How does RPC work? (Step 4)
The Return:
The server stub packs the result and sends it back to the client stub, which hands it to your code as if nothing unusual happened.
What is marshaling?
Gathering your parameters and packing them into a message format
What is unmarshaling
Unpacking the data
What is Remote Request?
When one computer asks another computer for information over a network.
What three things are involved in your computer making a remote request?
The Destination
The Method
The Payload
What is The Destination?
The address
What is The Method?
What you want to do
What is The Payload?
Any extra info the other computer needs to fulfill the request
What is a proxy/proxy server?
An intermediary that sits between the client and the internet.
What does a proxy/proxy server do?
Instead of your computer connecting directly to a website, your request goes to the proxy first, and the proxy talks to the website on your behalf, then returns the request to you.
What are the advantages of RPC?
It's simple, as the application developer simply calls the required procedure or function in the same way as a local procedure or function.
(This can speed up and simplify application development.)
What are the disadvantages of RPC?
Because the connection is abstracted, any delay or problem with connecting to the remote system can cause issues with the application, as the developer won't necessarily be able to mitigate these issues.
RPC can be vulnerable to security issues, as it does not natively provide security options.