gRPC core concepts

실리콘·2022년 10월 18일
0

docs

So what does gRPC do

gRPC enables writing code that will use another process kind of like an function. It is more complex than that, but that is a good place to start I thinik.

strange name

weird. gRPC stands for gRPC Remote Procedure Calls. A recursive acronym. so.. g is for google?

semantics?

it uses protocol buffer to define Interface Definition Language (IDL)

types of RPC supported

unaryRPC -> function
streamRPC -> client stream, server stream, bidrectional stream
so, total 4 kinds of RPC supported

sync, async supported

Deadlines/Timeouts

depends on application and language client. It can be a duration or a fixed time point. Default value may or may not be there.

RPC Termination

success or fail can be different for server and client. when RPC terminates, client may think it failed to send all requests, while server has finished job and sent back a successful response

Cancelling RPC

cancele anytime anywhere, but changes are not rolled back.

MetaData

form of key-value pairs. string, binary all possible. keys are not case sensitive. - _ . allowed. not start w/ grpc-. if binary, end with -bin.
metadata is opaque to gRPC .
accessing metadata depends on language client

Channels

provides connection to a gRPC server on a specified host and port.

profile
software engineer

0개의 댓글