Documentation
¶
Index ¶
- Variables
- func AlreadyAssigned(runtimeInfo base.RuntimeInfoInterface, node v1.Node) (assigned bool)
- func CanbeAssigned(runtimeInfo base.RuntimeInfoInterface, node v1.Node) bool
- func CheckIfRuntimeInNode(node v1.Node, runtimeInfo base.RuntimeInfoInterface) (found bool)
- func DecreaseDatasetNum(toUpdate *v1.Node, runtimeInfo base.RuntimeInfoInterface, ...) error
- func LabelCacheNode(nodeToLabel v1.Node, runtimeInfo base.RuntimeInfoInterface, ...) (err error)
- func UnlabelCacheNode(node v1.Node, runtimeInfo base.RuntimeInfoInterface, client client.Client) (err error)
Constants ¶
This section is empty.
Variables ¶
var SchedulerMutex = sync.Mutex{}
TODO: move this to some Scheduler-like struct SchedulerMutex is a mutex to protect the scheduling process from race condition
Functions ¶
func AlreadyAssigned ¶
func AlreadyAssigned(runtimeInfo base.RuntimeInfoInterface, node v1.Node) (assigned bool)
AlreadyAssigned checks if the node is already assigned the runtime engine If runtime engine cached dataset is exclusive, will check if any runtime engine already assigned the runtime engine
func CanbeAssigned ¶
func CanbeAssigned(runtimeInfo base.RuntimeInfoInterface, node v1.Node) bool
CanbeAssigned checks if the node is already assigned the runtime engine
func CheckIfRuntimeInNode ¶ added in v0.7.0
func CheckIfRuntimeInNode(node v1.Node, runtimeInfo base.RuntimeInfoInterface) (found bool)
CheckIfRuntimeInNode checks if the the runtime on this node
func DecreaseDatasetNum ¶ added in v0.6.0
func DecreaseDatasetNum(toUpdate *v1.Node, runtimeInfo base.RuntimeInfoInterface, labelsToModify *common.LabelsToModify) error
DecreaseDatasetNum deletes the datasetNum label or updates the number of the dataset in the specific node.
func LabelCacheNode ¶
func LabelCacheNode(nodeToLabel v1.Node, runtimeInfo base.RuntimeInfoInterface, client client.Client) (err error)
LabelCacheNode adds labels on a selected node to indicate the node is scheduled with corresponding runtime
func UnlabelCacheNode ¶ added in v0.7.0
func UnlabelCacheNode(node v1.Node, runtimeInfo base.RuntimeInfoInterface, client client.Client) (err error)
UnlabelCacheNode remove labels on a selected node to indicate the node doesn't have the cache for
Types ¶
This section is empty.