Skip to content

Commit f1befdc

Browse files
committed
server: Add ConnectionAuthenticated callback for some test handler implementations.
1 parent bb8eba5 commit f1befdc

File tree

3 files changed

+12
-0
lines changed

3 files changed

+12
-0
lines changed

server/extension.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,10 @@ func (ih *interceptorHandler) ConnectionClosed(c *mysql.Conn) {
156156
ih.h.ConnectionClosed(c)
157157
}
158158

159+
func (ih *interceptorHandler) ConnectionAuthenticated(c *mysql.Conn) error {
160+
return ih.h.ConnectionAuthenticated(c)
161+
}
162+
159163
func (ih *interceptorHandler) ConnectionAborted(c *mysql.Conn, reason string) error {
160164
return ih.h.ConnectionAborted(c, reason)
161165
}

server/golden/proxy.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -167,6 +167,10 @@ func (h MySqlProxy) ConnectionClosed(c *mysql.Conn) {
167167
delete(h.conns, c.ConnectionID)
168168
}
169169

170+
func (h MySqlProxy) ConnectionAuthenticated(c *mysql.Conn) error {
171+
return nil
172+
}
173+
170174
// ConnectionAborted implements mysql.Handler.
171175
func (h MySqlProxy) ConnectionAborted(c *mysql.Conn, reason string) error {
172176
return nil

server/golden/validator.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,10 @@ func (v Validator) ConnectionClosed(c *mysql.Conn) {
9191
v.golden.ConnectionClosed(c)
9292
}
9393

94+
func (v Validator) ConnectionAuthenticated(c *mysql.Conn) error {
95+
return nil
96+
}
97+
9498
func (v Validator) ConnectionAborted(c *mysql.Conn, reason string) error {
9599
return nil
96100
}

0 commit comments

Comments
 (0)