diff options
author | 2018-10-11 21:59:50 +0100 | |
---|---|---|
committer | 2018-10-11 16:59:50 -0400 | |
commit | 6ed88fab744bd3d8cc071153a4c78970798cf9e6 (patch) | |
tree | ab4935e8cb81931b65966ba13829f3f8780b12b3 /plugin/kubernetes/object/endpoint.go | |
parent | c8fb66f8cc60ff17b916b033982c5491f23cdcc9 (diff) | |
download | coredns-6ed88fab744bd3d8cc071153a4c78970798cf9e6.tar.gz coredns-6ed88fab744bd3d8cc071153a4c78970798cf9e6.tar.zst coredns-6ed88fab744bd3d8cc071153a4c78970798cf9e6.zip |
Revert "use keys (#2167)" (#2188)
This reverts commit 974ed086f25ad45a01947e276e2eb8aa73d007a3.
Diffstat (limited to 'plugin/kubernetes/object/endpoint.go')
-rw-r--r-- | plugin/kubernetes/object/endpoint.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/plugin/kubernetes/object/endpoint.go b/plugin/kubernetes/object/endpoint.go index a391c6426..b8531f050 100644 --- a/plugin/kubernetes/object/endpoint.go +++ b/plugin/kubernetes/object/endpoint.go @@ -40,7 +40,7 @@ type EndpointPort struct { } // EndpointsKey return a string using for the index. -func EndpointsKey(namespace, name string) string { return namespace + "/" + name } +func EndpointsKey(name, namespace string) string { return name + "." + namespace } // ToEndpoints converts an api.Service to a *Service. func ToEndpoints(obj interface{}) interface{} { @@ -61,7 +61,7 @@ func ToEndpoints(obj interface{}) interface{} { Addresses: make([]EndpointAddress, len(eps.Addresses)), } if len(eps.Ports) == 0 { - // Add sentinel if there are no ports. + // Add sentinal if there are no ports. sub.Ports = []EndpointPort{{Port: -1}} } else { sub.Ports = make([]EndpointPort, len(eps.Ports)) |