noderesourcetopologies

package
v0.4.12-0.2022110301 Latest Latest
Warning

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

Go to latest
Published: Nov 3, 2022 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNotEnoughResources = errors.New("nrt: Not enough resources")

ErrNotEnoughResources means a NUMA zone or a node has not enough resouces to reserve

Functions

func AccumulateNames

func AccumulateNames(nrts []nrtv1alpha1.NodeResourceTopology) sets.String

func AvailableFromZone

func AvailableFromZone(z nrtv1alpha1.Zone) corev1.ResourceList

AvailableFromZone returns a ResourceList of all available resources under the zone

func CheckEqualAvailableResources

func CheckEqualAvailableResources(nrtInitial, nrtUpdated nrtv1alpha1.NodeResourceTopology) (bool, error)

func CheckNodeConsumedResourcesAtLeast

func CheckNodeConsumedResourcesAtLeast(nrtInitial, nrtUpdated nrtv1alpha1.NodeResourceTopology, required corev1.ResourceList, podQoS corev1.PodQOSClass) (string, error)

func CheckZoneConsumedResourcesAtLeast

func CheckZoneConsumedResourcesAtLeast(nrtInitial, nrtUpdated nrtv1alpha1.NodeResourceTopology, required corev1.ResourceList, podQoS corev1.PodQOSClass) (string, error)

func FindResourceAllocatableByName

func FindResourceAllocatableByName(resources []nrtv1alpha1.ResourceInfo, name string) (resource.Quantity, bool)

func FindResourceAvailableByName

func FindResourceAvailableByName(resources []nrtv1alpha1.ResourceInfo, name string) (resource.Quantity, bool)

func GetMaxAllocatableResourceNumaLevel

func GetMaxAllocatableResourceNumaLevel(nrtInfo nrtv1alpha1.NodeResourceTopology, resName corev1.ResourceName) resource.Quantity

func GetZoneIDFromName

func GetZoneIDFromName(zoneName string) (int, error)

func ResourceInfoListToResourceList

func ResourceInfoListToResourceList(ri nrtv1alpha1.ResourceInfoList) corev1.ResourceList

func SaturateNodeUntilLeft

func SaturateNodeUntilLeft(nrtInfo nrtv1alpha1.NodeResourceTopology, requiredRes corev1.ResourceList) (map[string]corev1.ResourceList, error)

func SaturateZoneUntilLeft

func SaturateZoneUntilLeft(zone nrtv1alpha1.Zone, requiredRes corev1.ResourceList) (corev1.ResourceList, error)

func ZoneResourcesMatchesRequest

func ZoneResourcesMatchesRequest(resources []nrtv1alpha1.ResourceInfo, requests corev1.ResourceList) bool

Types

This section is empty.

Jump to

Keyboard shortcuts

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