1
0
mirror of https://github.com/redis/go-redis.git synced 2025-07-28 06:42:00 +03:00

Add Options.OnConnect

This commit is contained in:
Vladimir Mihailenco
2017-05-25 14:16:39 +03:00
parent 7e8890b644
commit 4a3a300665
7 changed files with 101 additions and 14 deletions

View File

@ -24,6 +24,9 @@ type Options struct {
// Network and Addr options.
Dialer func() (net.Conn, error)
// Hook that is called when new connection is established.
OnConnect func(*Conn) error
// Optional password. Must match the password specified in the
// requirepass server configuration option.
Password string