File tree 1 file changed +4
-5
lines changed
1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change 6
6
"strings"
7
7
8
8
corev1 "k8s.io/api/core/v1"
9
- v1 "k8s.io/api/core/v1"
10
9
"k8s.io/apimachinery/pkg/labels"
11
10
"k8s.io/apimachinery/pkg/types"
12
11
)
@@ -33,11 +32,11 @@ func parseSelector(v string) (labels.Selector, error) {
33
32
return labels .SelectorFromSet (labels .Set (m )), nil
34
33
}
35
34
36
- func podToEndpointAddress (pod * v1 .Pod ) * v1 .EndpointAddress {
37
- return & v1 .EndpointAddress {
35
+ func podToEndpointAddress (pod * corev1 .Pod ) * corev1 .EndpointAddress {
36
+ return & corev1 .EndpointAddress {
38
37
IP : pod .Status .PodIP ,
39
38
NodeName : & pod .Spec .NodeName ,
40
- TargetRef : & v1 .ObjectReference {
39
+ TargetRef : & corev1 .ObjectReference {
41
40
Kind : "Pod" ,
42
41
Namespace : pod .Namespace ,
43
42
Name : pod .Name ,
@@ -46,7 +45,7 @@ func podToEndpointAddress(pod *v1.Pod) *v1.EndpointAddress {
46
45
}}
47
46
}
48
47
49
- func endpointChanged (pod1 , pod2 * v1 .Pod ) bool {
48
+ func endpointChanged (pod1 , pod2 * corev1 .Pod ) bool {
50
49
endpointAddress1 := podToEndpointAddress (pod1 )
51
50
endpointAddress2 := podToEndpointAddress (pod2 )
52
51
You can’t perform that action at this time.
0 commit comments