Commit 5cb0a823 authored by Nane Kratzke's avatar Nane Kratzke
Browse files

Call exceptions

parent 0f5a29c3
......@@ -23,11 +23,17 @@ def monitor():
for i in range(0, n):
start = time.time()
try:
x = stub.SayHello(helloworld_pb2.HelloRequest(name='you'))
except:
print(f"Error gRPC call { grpc_svc }:{ grpc_port }")
grpc_s.append(time.time() - start)
start = time.time()
try:
y = requests.get(f"http://{ rest_svc }:{ rest_port }/hello/you")
except:
print(f"Error GET http://{ rest_svc }:{ rest_port }/hello/you")
rest_s.append(time.time() - start)
return ", ".join([
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment