waitingpod

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 20, 2021 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handle

type Handle interface {
	// GetWaitingPod returns a waiting pod given its UID.
	GetWaitingPod(uid types.UID) *WaitingPod
}

type WaitingPod

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

WaitingPod represents a pod waiting in the permit phase.

func NewWaitingPod

func NewWaitingPod(pod *v1.Pod, pluginsMaxWaitTime map[string]time.Duration) *WaitingPod

NewWaitingPod returns a new WaitingPod instance.

func (*WaitingPod) Allow

func (w *WaitingPod) Allow(pluginName string)

Allow declares the waiting pod is allowed to be scheduled by plugin pluginName. If this is the last remaining plugin to allow, then a success signal is delivered to unblock the pod.

func (*WaitingPod) GetPendingPlugins

func (w *WaitingPod) GetPendingPlugins() []string

GetPendingPlugins returns a list of pending permit plugin's name.

func (*WaitingPod) GetPod

func (w *WaitingPod) GetPod() *v1.Pod

GetPod returns a reference to the waiting pod.

func (*WaitingPod) GetSignal

func (w *WaitingPod) GetSignal() *framework.Status

GetSignal returns a signal from plugin It blocks until get signal

func (*WaitingPod) Reject

func (w *WaitingPod) Reject(pluginName, msg string)

Reject declares the waiting pod unschedulable.

Jump to

Keyboard shortcuts

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