This commit is contained in:
Dmitrii Dolgov 2025-10-21 15:03:22 +02:00 committed by GitHub
commit 3c712dacb2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 5 additions and 1 deletions

View File

@ -216,7 +216,11 @@ func (c *Cluster) getConnectionPoolerEnvVars() []v1.EnvVar {
maxDBConn := *effectiveMaxDBConn / *numberOfInstances
defaultSize := maxDBConn / 2
// Following pooler parameters are per pool, which means they have to be
// calculated from the global max db connections adjusted by the number of
// pairs (database, user).
numberOfPools := int32(len(spec.Users) * len(spec.Databases))
defaultSize := (maxDBConn / numberOfPools) / 2
minSize := defaultSize / 2
reserveSize := minSize