Remove Port from registry

This commit is contained in:
Asim Aslam
2019-07-08 08:01:42 +01:00
parent 5b7454e5a8
commit e0bf1c2283
35 changed files with 92 additions and 228 deletions

View File

@@ -3,7 +3,6 @@ package mucp
import (
"context"
"fmt"
"io"
"os"
"strings"
@@ -157,11 +156,7 @@ func (p *Proxy) getRoute(service string) ([]string, error) {
for _, service := range services {
for _, node := range service.Nodes {
addr := node.Address
if node.Port > 0 {
addr = fmt.Sprintf("%s:%d", node.Address, node.Port)
}
addrs = append(addrs, addr)
addrs = append(addrs, node.Address)
}
}
}