aboutsummaryrefslogtreecommitdiff
path: root/src/database/sql/driver/driver.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/database/sql/driver/driver.go')
-rw-r--r--src/database/sql/driver/driver.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/database/sql/driver/driver.go b/src/database/sql/driver/driver.go
index a2b844d71f..76f1bd3aa1 100644
--- a/src/database/sql/driver/driver.go
+++ b/src/database/sql/driver/driver.go
@@ -261,15 +261,15 @@ type SessionResetter interface {
ResetSession(ctx context.Context) error
}
-// ConnectionValidator may be implemented by Conn to allow drivers to
+// Validator may be implemented by Conn to allow drivers to
// signal if a connection is valid or if it should be discarded.
//
// If implemented, drivers may return the underlying error from queries,
// even if the connection should be discarded by the connection pool.
-type ConnectionValidator interface {
- // ValidConnection is called prior to placing the connection into the
+type Validator interface {
+ // IsValid is called prior to placing the connection into the
// connection pool. The connection will be discarded if false is returned.
- ValidConnection() bool
+ IsValid() bool
}
// Result is the result of a query execution.