What changed, and why it matters
This commit only fixes three incorrect sentences in the user-facing documentation for database connection settings. It does not change any code behavior, defaults, or limits. There is no security issue in the commit itself.
No security action needed. This is a documentation-only clarification. Operators who previously relied on the inaccurate 'unlimited' wording should note that 0 uses default connection limits, not unlimited connections, but this behavior was already in place before the commit.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The patch updates the struct tag descriptions in sqldb/v2/config.go for SqliteConfig.MaxConnections, PostgresConfig.MaxOpenConnections, and PostgresConfig.MaxIdleConnections. The old descriptions claimed that setting the value to 0 meant ‘unlimited’ connections, which was inaccurate; the actual behavior is that 0 falls back to the underlying driver’s default values. The commit removes the misleading ‘Set to zero for unlimited’ wording. No logic, validation, or default values were modified.
Changed components
sqldb/v2/config.go documentation stringsInspect captured patch +3 / −3
diff --git a/sqldb/v2/config.go b/sqldb/v2/config.go
index b7516c0..d02565e 100644
--- a/sqldb/v2/config.go
+++ b/sqldb/v2/config.go
@@ -33,7 +33,7 @@ const (
type SqliteConfig struct {
Timeout time.Duration `long:"timeout" description:"The time after which a database query should be timed out."`
BusyTimeout time.Duration `long:"busytimeout" description:"The maximum amount of time to wait for a database connection to become available for a query."`
- MaxConnections int `long:"maxconnections" description:"The maximum number of open connections to the database. Set to zero for unlimited."`
+ MaxConnections int `long:"maxconnections" description:"The maximum number of open connections to the database."`
PragmaOptions []string `long:"pragmaoptions" description:"A list of pragma options to set on a database connection. For example, 'auto_vacuum=incremental'. Note that the flag must be specified multiple times if multiple options are to be set."`
SkipMigrations bool `long:"skipmigrations" description:"Skip applying migrations on startup."`
@@ -75,8 +75,8 @@ func (p *SqliteConfig) Validate() error {
type PostgresConfig struct {
Dsn string `long:"dsn" description:"Database connection string."`
Timeout time.Duration `long:"timeout" description:"Database connection timeout. Set to zero to disable."`
- MaxOpenConnections int `long:"maxconnections" description:"Max open connections to keep alive to the database server. Set to zero for unlimited."`
- MaxIdleConnections int `long:"maxidleconnections" description:"Max number of idle connections to keep in the connection pool. Set to zero for unlimited."`
+ MaxOpenConnections int `long:"maxconnections" description:"Max open connections to keep alive to the database server."`
+ MaxIdleConnections int `long:"maxidleconnections" description:"Max number of idle connections to keep in the connection pool."`
ConnMaxLifetime time.Duration `long:"connmaxlifetime" description:"Max amount of time a connection can be reused for before it is closed. Valid time units are {s, m, h}."`
ConnMaxIdleTime time.Duration `long:"connmaxidletime" description:"Max amount of time a connection can be idle for before it is closed. Valid time units are {s, m, h}."`
RequireSSL bool `long:"requiressl" description:"Whether to require using SSL (mode: require) when connecting to the server."`
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.