2
0

Deprecate CheckConn in favor of Ping

This commit is contained in:
Jack Christensen
2023-06-03 18:54:58 -05:00
committed by Jack Christensen
parent 26c79eb215
commit 3ea2f57d8b
4 changed files with 67 additions and 20 deletions
+1 -1
View File
@@ -504,7 +504,7 @@ func (p *Pool) Acquire(ctx context.Context) (*Conn, error) {
cr := res.Value()
if res.IdleDuration() > time.Second {
err := cr.conn.PgConn().CheckConn()
err := cr.conn.Ping(ctx)
if err != nil {
res.Destroy()
continue