Decrease grpc client dial timeout to one second (#1378)

This commit is contained in:
Ori Newman 2021-01-07 16:26:37 +02:00 committed by GitHub
parent 82d95c59a3
commit 256b7f25f1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -24,7 +24,7 @@ type GRPCClient struct {
// Connect connects to the RPC server with the given address
func Connect(address string) (*GRPCClient, error) {
const dialTimeout = 30 * time.Second
const dialTimeout = 1 * time.Second
ctx, cancel := context.WithTimeout(context.Background(), dialTimeout)
defer cancel()