mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-14 21:53:52 +00:00
@@ -180,7 +180,7 @@ func (rs *RegistryStorage) ResourceLocation(id string) (string, error) {
|
||||
if len(e.Endpoints) == 0 {
|
||||
return "", fmt.Errorf("no endpoints available for %v", id)
|
||||
}
|
||||
return e.Endpoints[rand.Intn(len(e.Endpoints))], nil
|
||||
return "http://" + e.Endpoints[rand.Intn(len(e.Endpoints))], nil
|
||||
}
|
||||
|
||||
func (rs *RegistryStorage) deleteExternalLoadBalancer(service *api.Service) error {
|
||||
|
@@ -291,7 +291,7 @@ func TestServiceRegistryResourceLocation(t *testing.T) {
|
||||
if err != nil {
|
||||
t.Errorf("Unexpected error: %v", err)
|
||||
}
|
||||
if e, a := "foo:80", location; e != a {
|
||||
if e, a := "http://foo:80", location; e != a {
|
||||
t.Errorf("Expected %v, but got %v", e, a)
|
||||
}
|
||||
if e, a := "foo", registry.GottenID; e != a {
|
||||
|
Reference in New Issue
Block a user