mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-11-22 19:44:36 +00:00
plugin/scheduler
This commit is contained in:
@@ -16,11 +16,11 @@ limitations under the License.
|
||||
|
||||
package schedulercache
|
||||
|
||||
import "k8s.io/kubernetes/pkg/api"
|
||||
import "k8s.io/kubernetes/pkg/api/v1"
|
||||
|
||||
// CreateNodeNameToInfoMap obtains a list of pods and pivots that list into a map where the keys are node names
|
||||
// and the values are the aggregated information for that node.
|
||||
func CreateNodeNameToInfoMap(pods []*api.Pod, nodes []*api.Node) map[string]*NodeInfo {
|
||||
func CreateNodeNameToInfoMap(pods []*v1.Pod, nodes []*v1.Node) map[string]*NodeInfo {
|
||||
nodeNameToInfo := make(map[string]*NodeInfo)
|
||||
for _, pod := range pods {
|
||||
nodeName := pod.Spec.NodeName
|
||||
|
||||
Reference in New Issue
Block a user