mirror of
https://github.com/jackc/pgx.git
synced 2025-07-11 13:08:49 +00:00
Fix error message
This commit is contained in:
parent
11e1f70c32
commit
d05661b5ee
@ -132,7 +132,7 @@ func OpenFromConnPool(pool *pgx.ConnPool) (*sql.DB, error) {
|
||||
stat := pool.Stat()
|
||||
|
||||
if stat.MaxConnections <= 2 {
|
||||
return nil, errors.New("pool connection size must be at least 2")
|
||||
return nil, errors.New("pool connection size must be at least 3")
|
||||
}
|
||||
db.SetMaxIdleConns(stat.MaxConnections - 2)
|
||||
db.SetMaxOpenConns(stat.MaxConnections)
|
||||
|
Loading…
x
Reference in New Issue
Block a user