allocator

package
v0.0.0-...-1f6a80c Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AllocateResult

type AllocateResult = types.NamespacedName

type Allocator

type Allocator interface {
	// Allocate allocates a DPUCluster for DPU
	Allocate(context.Context, *provisioningv1.DPU) (AllocateResult, error)
	// SaveAssignedDPU stores assigned DPU to cache
	SaveAssignedDPU(*provisioningv1.DPU)
	// SaveCluster updates cached DPUCluster with the given one
	SaveCluster(*provisioningv1.DPUCluster)
	// ReleaseDPU releases the given DPU from its allocated DPUCluster
	ReleaseDPU(*provisioningv1.DPU)
	// RemoveCluster removes given DPUCluster from cache
	RemoveCluster(dc *provisioningv1.DPUCluster)
}

Allocator allocates DPUCluster for DPUs. This is just a temporary solution for Oct Rel, and we will implement a more complex allocator in a dedicated controller in future releases

func NewAllocator

func NewAllocator(client client.Client) Allocator

type ClusterCache

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

ClusterCache caches DPUClusters and to which DPUs they are allocated.

type ClusterInfo

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

Jump to

Keyboard shortcuts

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