Skip to content

Commit

Permalink
Set connection timeout for cassandra tool (#1277)
Browse files Browse the repository at this point in the history
  • Loading branch information
wxing1292 authored Feb 10, 2021
1 parent 677e0d1 commit cf20471
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions tools/cassandra/cqlclient.go
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@ func NewCassandraCluster(cfg *config.Cassandra, timeoutSeconds int) (*gocql.Clus
}

timeout := time.Duration(timeoutSeconds) * time.Second
clusterCfg.ConnectTimeout = timeout
clusterCfg.Timeout = timeout
clusterCfg.ProtoVersion = cqlProtoVersion
clusterCfg.Consistency = cfg.Consistency.GetConsistency()
Expand Down

0 comments on commit cf20471

Please sign in to comment.