File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
platform/fabricx/core/queryservice Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -11,6 +11,7 @@ import (
1111 "time"
1212
1313 "github.com/hyperledger-labs/fabric-smart-client/pkg/utils/errors"
14+ grpc2 "github.com/hyperledger-labs/fabric-smart-client/platform/view/services/grpc"
1415 "google.golang.org/grpc"
1516 "google.golang.org/grpc/backoff"
1617 "google.golang.org/grpc/credentials"
@@ -36,6 +37,11 @@ func GrpcClient(c *Config) (*grpc.ClientConn, error) {
3637 var opts []grpc.DialOption
3738 opts = append (opts , WithConnectionTime (endpoint .ConnectionTimeout ))
3839 opts = append (opts , WithTLS (endpoint ))
40+ opts = append (opts , grpc2 .ClientKeepaliveOptions (
41+ grpc2.KeepaliveOptions {
42+ ClientInterval : 60 * time .Second ,
43+ ClientTimeout : 600 * time .Second ,
44+ })... )
3945
4046 return grpc .NewClient (endpoint .Address , opts ... )
4147}
You can’t perform that action at this time.
0 commit comments