@@ -28,12 +28,12 @@ import (
28
28
"k8s.io/kubernetes/pkg/scheduler/framework/plugins/nodename"
29
29
"k8s.io/kubernetes/pkg/scheduler/framework/plugins/nodeports"
30
30
"k8s.io/kubernetes/pkg/scheduler/framework/plugins/noderesources"
31
- framework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
31
+ schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
32
32
)
33
33
34
34
type getNodeAnyWayFuncType func () (* v1.Node , error )
35
35
36
- type pluginResourceUpdateFuncType func (* framework .NodeInfo , * PodAdmitAttributes ) error
36
+ type pluginResourceUpdateFuncType func (* schedulerframework .NodeInfo , * PodAdmitAttributes ) error
37
37
38
38
// AdmissionFailureHandler is an interface which defines how to deal with a failure to admit a pod.
39
39
// This allows for the graceful handling of pod admission failure.
@@ -69,7 +69,7 @@ func (w *predicateAdmitHandler) Admit(attrs *PodAdmitAttributes) PodAdmitResult
69
69
}
70
70
admitPod := attrs .Pod
71
71
pods := attrs .OtherPods
72
- nodeInfo := framework .NewNodeInfo (pods ... )
72
+ nodeInfo := schedulerframework .NewNodeInfo (pods ... )
73
73
nodeInfo .SetNode (node )
74
74
// ensure the node has enough plugin resources for that required in pods
75
75
if err = w .pluginResourceUpdateFunc (nodeInfo , attrs ); err != nil {
@@ -155,7 +155,7 @@ func (w *predicateAdmitHandler) Admit(attrs *PodAdmitAttributes) PodAdmitResult
155
155
}
156
156
}
157
157
158
- func removeMissingExtendedResources (pod * v1.Pod , nodeInfo * framework .NodeInfo ) * v1.Pod {
158
+ func removeMissingExtendedResources (pod * v1.Pod , nodeInfo * schedulerframework .NodeInfo ) * v1.Pod {
159
159
podCopy := pod .DeepCopy ()
160
160
for i , c := range pod .Spec .Containers {
161
161
// We only handle requests in Requests but not Limits because the
@@ -219,7 +219,7 @@ func (e *PredicateFailureError) GetReason() string {
219
219
}
220
220
221
221
// GeneralPredicates checks a group of predicates that the kubelet cares about.
222
- func GeneralPredicates (pod * v1.Pod , nodeInfo * framework .NodeInfo ) ([]PredicateFailureReason , error ) {
222
+ func GeneralPredicates (pod * v1.Pod , nodeInfo * schedulerframework .NodeInfo ) ([]PredicateFailureReason , error ) {
223
223
if nodeInfo .Node () == nil {
224
224
return nil , fmt .Errorf ("node not found" )
225
225
}
0 commit comments