Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Extender ¶
type Extender struct { sync.Mutex // contains filtered or unexported fields } // if a new field is added, add field to extender_test.go also.
Extender holds http handlers for scheduler extender endpoints and implements logic for nodes filtering based on pod volumes requirements and Available Capacities
func NewExtender ¶
func NewExtender(logger *logrus.Logger, kubeClient *k8s.KubeClient, kubeCache *k8s.KubeCache, provisioner string, featureConf fc.FeatureChecker, annotationKey, nodeselector string) (*Extender, error)
NewExtender returns new instance of Extender struct
func (*Extender) BindHandler ¶
func (e *Extender) BindHandler(w http.ResponseWriter, req *http.Request)
BindHandler does bind of a pod to specific node
func (*Extender) FilterHandler ¶
func (e *Extender) FilterHandler(w http.ResponseWriter, req *http.Request)
FilterHandler extracts ExtenderArgs struct from req and writes ExtenderFilterResult to the w
func (*Extender) PrioritizeHandler ¶
func (e *Extender) PrioritizeHandler(w http.ResponseWriter, req *http.Request)
PrioritizeHandler helps with even distribution of the volumes across the nodes. It will set priority based on the formula: rank of node X = max number of volumes - number of volume on node X.
Click to show internal directories.
Click to hide internal directories.