Skip to content

Commit

Permalink
Fix: GetServer expects a connection string with the protocol
Browse files Browse the repository at this point in the history
  • Loading branch information
roivaz committed Sep 5, 2024
1 parent ea9bad4 commit ac17a97
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/redis/server/pool.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,8 @@ func (pool *ServerPool) indexByHostPort() map[string]*Server {
return index
}

func (pool *ServerPool) GetServerAlias(connectionString string) string {
if srv, err := pool.GetServer(connectionString, nil); err == nil {
func (pool *ServerPool) GetServerAlias(hostport string) string {
if srv, err := pool.GetServer("redis://"+hostport, nil); err == nil {
return srv.alias
} else {
return ""
Expand Down

0 comments on commit ac17a97

Please sign in to comment.