File: README.en.md

package info (click to toggle)
grpc 1.51.1-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 76,144 kB
  • sloc: cpp: 361,866; python: 72,206; ansic: 37,778; objc: 12,434; ruby: 11,521; sh: 7,652; php: 7,615; makefile: 3,481; xml: 3,246; cs: 1,836; javascript: 1,614; java: 465; pascal: 227; awk: 132
file content (37 lines) | stat: -rw-r--r-- 1,050 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
##  Data transmission demo for using gRPC in Python

Four ways of data transmission when gRPC is used in Python.  [Official Guide](<https://grpc.io/docs/guides/concepts/#unary-rpc>)

- #### unary-unary

  In a single call, the client can only send request once, and the server can only respond once.

  `client.py: simple_method`

  `server.py: SimpleMethod`

- #### stream-unary

  In a single call, the client can transfer data to the server an arbitrary number of times, but the server can only return a response once.

  `client.py: client_streaming_method`

  `server.py: ClientStreamingMethod`

- #### unary-stream

  In a single call, the client can only transmit data to the server at one time, but the server can return the response many times.

  `client.py: server_streaming_method`

  `server.py: ServerStreamingMethod`

- #### stream-stream

  In a single call, both client and server can send and receive data 
  to each other multiple times.

  `client.py: bidirectional_streaming_method`

  `server.py: BidirectionalStreamingMethod`