gRPCClient.jl
gRPCClient.jl copied to clipboard
SayHello latencies are unexpectedly high
Compared with the example C++ client https://github.com/grpc/grpc/blob/master/examples/cpp/helloworld/greeter_client.cc, which gets around 20μs, I'm getting ~300μs when connecting to localhost. I haven't tested this yet with a remote tcp connection. I can't use BenchmarkTools because of #33
julia> for _=1:20; sleep(0.001); @time HelloworldClients.SayHello(client, HelloworldClients.helloworld.HelloRequest(name="Hello world")); end
0.000507 seconds (336 allocations: 19.344 KiB)
0.000283 seconds (335 allocations: 19.578 KiB)
0.000285 seconds (335 allocations: 19.312 KiB)
0.000272 seconds (336 allocations: 19.344 KiB)
0.001025 seconds (337 allocations: 19.641 KiB)
0.000300 seconds (336 allocations: 19.344 KiB)
0.000303 seconds (336 allocations: 19.344 KiB)
0.000308 seconds (337 allocations: 19.641 KiB)
0.000301 seconds (336 allocations: 19.344 KiB)
0.000309 seconds (336 allocations: 19.344 KiB)
0.000293 seconds (337 allocations: 19.641 KiB)
0.000290 seconds (336 allocations: 19.344 KiB)
0.000301 seconds (336 allocations: 19.344 KiB)
0.000296 seconds (337 allocations: 19.641 KiB)
0.000299 seconds (336 allocations: 19.344 KiB)
0.000295 seconds (336 allocations: 19.344 KiB)
0.000298 seconds (337 allocations: 19.641 KiB)
0.000275 seconds (335 allocations: 19.312 KiB)
0.000285 seconds (336 allocations: 19.344 KiB)
0.000292 seconds (337 allocations: 19.641 KiB)