Add requirements.txt

pull/22460/head
Richard Belleville 5 years ago
parent 571a564f51
commit f64e7af7cd
  1. 2
      examples/python/xds/README.md
  2. 5
      examples/python/xds/requirements.txt
  3. 2
      examples/python/xds/server.py

@ -22,7 +22,7 @@ cd grpc/examples/python/xds
```sh
virtualenv venv -p python3
source venv/bin/activate
pip install grpcio protobuf grpcio-reflection grpcio-health-checking
pip install -r requirements.txt
python server.py
```

@ -0,0 +1,5 @@
grpcio>=1.28.0
protobuf
grpcio-reflection
grpcio-health-checking

@ -43,7 +43,7 @@ class Greeter(helloworld_pb2_grpc.GreeterServicer):
message=f"Hello {request.name} from {self._hostname}!")
def serve(port, hostname):
def serve(port: int, hostname: str):
server = grpc.server(
futures.ThreadPoolExecutor(max_workers=multiprocessing.cpu_count()))

Loading…
Cancel
Save