Documentation ¶
Index ¶
- func QuantityToInt64RoundDown(q resource.Quantity, scale resource.Scale) int64
- func QuantityToInt64RoundUp(q resource.Quantity, scale resource.Scale) int64
- type Node
- func (node *Node) FindMatchingUntoleratedTaint(tolerations ...[]v1.Toleration) (v1.Taint, bool)
- func (node *Node) GetExecutor() string
- func (node *Node) GetId() string
- func (node *Node) GetIndex() uint64
- func (node *Node) GetLabelValue(key string) (string, bool)
- func (node *Node) GetLabels() map[string]string
- func (node *Node) GetName() string
- func (node *Node) GetNodeTypeId() uint64
- func (node *Node) GetTaints() []v1.Taint
- func (node *Node) GetTolerationsForTaints() []v1.Toleration
- func (node *Node) MatchNodeSelectorTerms(nodeSelector *v1.NodeSelector) (bool, error)
- func (node *Node) UnsafeCopy() *Node
- type ResourceList
- type ResourceListFactory
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func QuantityToInt64RoundDown ¶ added in v0.4.48
Types ¶
type Node ¶
type Node struct { TotalResources schedulerobjects.ResourceList // This field is set when inserting the Node into a NodeDb. Keys [][]byte AllocatableByPriority schedulerobjects.AllocatableByPriorityAndResourceType AllocatedByQueue map[string]schedulerobjects.ResourceList AllocatedByJobId map[string]schedulerobjects.ResourceList EvictedJobRunIds map[string]bool // contains filtered or unexported fields }
func CreateNode ¶ added in v0.4.37
func CreateNode( id string, nodeTypeId uint64, index uint64, executor string, name string, taints []v1.Taint, labels map[string]string, totalResources schedulerobjects.ResourceList, allocatableByPriority schedulerobjects.AllocatableByPriorityAndResourceType, allocatedByQueue map[string]schedulerobjects.ResourceList, allocatedByJobId map[string]schedulerobjects.ResourceList, evictedJobRunIds map[string]bool, keys [][]byte, ) *Node
func (*Node) FindMatchingUntoleratedTaint ¶ added in v0.4.40
func (*Node) GetExecutor ¶ added in v0.4.37
func (*Node) GetLabelValue ¶ added in v0.4.40
func (*Node) GetNodeTypeId ¶ added in v0.4.37
func (*Node) GetTolerationsForTaints ¶ added in v0.4.40
func (node *Node) GetTolerationsForTaints() []v1.Toleration
func (*Node) MatchNodeSelectorTerms ¶ added in v0.4.40
func (node *Node) MatchNodeSelectorTerms(nodeSelector *v1.NodeSelector) (bool, error)
func (*Node) UnsafeCopy ¶
UnsafeCopy returns a pointer to a new value of type Node; it is unsafe because it only makes shallow copies of fields that are not mutated by methods of NodeDb.
type ResourceList ¶ added in v0.4.48
type ResourceList struct {
// contains filtered or unexported fields
}
type ResourceListFactory ¶ added in v0.4.48
type ResourceListFactory struct {
// contains filtered or unexported fields
}
func MakeResourceListFactory ¶ added in v0.4.48
func MakeResourceListFactory(supportedResourceTypes []configuration.ResourceType) (*ResourceListFactory, error)
func (*ResourceListFactory) FromJobProto ¶ added in v0.4.48
func (factory *ResourceListFactory) FromJobProto(resources schedulerobjects.ResourceList) (ResourceList, error)
Fail on unknown resources, round up.
func (*ResourceListFactory) FromNodeProto ¶ added in v0.4.48
func (factory *ResourceListFactory) FromNodeProto(resources schedulerobjects.ResourceList) ResourceList
Ignore unknown resources, round down.
func (*ResourceListFactory) SummaryString ¶ added in v0.4.48
func (factory *ResourceListFactory) SummaryString() string
Click to show internal directories.
Click to hide internal directories.