diff --git a/pgconn/config.go b/pgconn/config.go index 3cd5d8773..5f448a3ea 100644 --- a/pgconn/config.go +++ b/pgconn/config.go @@ -294,7 +294,10 @@ func ParseConfigWithOptions(connString string, options ParseConfigOptions) (*Con return pgproto3.NewFrontend(r, w) }, BuildContextWatcherHandler: func(pgConn *PgConn) ctxwatch.Handler { - return &DeadlineContextWatcherHandler{Conn: pgConn.conn} + return &DeadlineContextWatcherHandler{ + Conn: pgConn.conn, + DeadlineDelay: 50 * time.Millisecond, + } }, OnPgError: func(_ *PgConn, pgErr *PgError) bool { // we want to automatically close any fatal errors