mig

package
v0.0.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 24, 2025 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

View Source
const Name = "MigAccelerator"

Variables

This section is empty.

Functions

func New

New initializes a new plugin and returns it.

Types

type Args

type Args struct {
	Namespace string `json:"namespace,omitempty"`
}

Args holds the scheduler plugin configuration.

type Plugin

type Plugin struct {
	// contains filtered or unexported fields
}

Plugin implements a scheduler Filter extension for GPU allocation.

func (*Plugin) Filter

func (p *Plugin) Filter(ctx context.Context, state *framework.CycleState, pod *corev1.Pod, nodeInfo *framework.NodeInfo) *framework.Status

Filter checks if the given node has an available MIG slice for the pod.

func (*Plugin) Name

func (p *Plugin) Name() string

Name returns the plugin name.

func (*Plugin) PreBind

func (p *Plugin) PreBind(ctx context.Context, state *framework.CycleState, pod *corev1.Pod, nodeName string) *framework.Status

PreBind finalizes AllocationClaims on the chosen node and cleans up staged claims on the other nodes.

func (*Plugin) Score

func (p *Plugin) Score(ctx context.Context, state *framework.CycleState, pod *corev1.Pod, nodeName string) (int64, *framework.Status)

Score favors nodes with the most remaining free MIG slice capacity after accounting for all AllocationClaims including those staged for this Pod.

func (*Plugin) ScoreExtensions

func (p *Plugin) ScoreExtensions() framework.ScoreExtensions

ScoreExtensions returns nil as the plugin does not implement score extensions.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL