Huawei Certified ICT Expert – Routing and Switching (HCIE-RS) — Question 18
gRPC is a language-neutral, platform-neutral, and open source remote RPC system and supports the service methods of unary RPCs and streaming RPCs. Which of the following service methods are not supported by gRPC? (Choose all that apply.)
Answer options
- A. rpc Cancel(CancelArgs) returns(Cancel Reply) {};
- B. rpc Subscribe(SubsArgs) stream returns(Subs Reply) {};
- C. rpc stream LotsOfGreetings(HelloRequest) returns (HelloResponse) {};
- D. rpc dataPublish(stream serviceArgs) returns(stream serviceArgs) {};
Correct answer: D
Explanation
gRPC does not support the service method defined in option D because it does not allow for a streaming input and output in the same RPC method. Options A, B, and C are valid service methods that adhere to gRPC's specifications for either unary or streaming RPCs.