From d0a8589aef329c97eca502b459e926c9cc8456c4 Mon Sep 17 00:00:00 2001 From: "mykyta.oleksiienko" Date: Thu, 12 Sep 2024 17:44:07 +0300 Subject: [PATCH] Detailed description for NumConns. NumConns doesn`t have a proper description, so it could cause misunderstanding and confusion about this option. patch by Mykyta Oleksiienko; reviewed by Joao Reis and Jackson Fleming for CASSGO-3 --- cluster.go | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/cluster.go b/cluster.go index 780621182..d54a4d534 100644 --- a/cluster.go +++ b/cluster.go @@ -89,7 +89,13 @@ type ClusterConfig struct { // Initial keyspace. Optional. Keyspace string - // Number of connections per host. + // The size of the connection pool for each host. + // The pool filling runs in separate gourutine during the session initialization phase. + // gocql will always try to get 1 connection on each host pool + // during session initialization AND it will attempt + // to fill each pool afterward asynchronously if NumConns > 1. + // Notice: There is no guarantee that pool filling will be finished in the initialization phase. + // Also, it describes a maximum number of connections at the same time. // Default: 2 NumConns int