policy

package
v0.0.0-...-ee6f436 Latest Latest
Warning

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

Go to latest
Published: Feb 24, 2025 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetPlacement

func GetPlacement(balancer *v1alpha1.Balancer, summaries map[string]pods.Summary) (ReplicaPlacement, PlacementProblems, error)

GetPlacement calculates the placement for the given balancer and pod summary information for individual balancer targets.

Types

type PlacementProblems

type PlacementProblems struct {
	// MissingReplicas is the number of replicas that had to be added
	// on top of the desired count to match the constraint and policy.
	MissingReplicas int32
	// OverflowReplicas is the number of replicas that could not be placed
	// due to constraints and policy.
	OverflowReplicas int32
}

PlacementProblems contains information about replicas that were problematic when applying placement policy and constraints.

type ReplicaPlacement

type ReplicaPlacement map[string]int32

ReplicaPlacement defines the number of replicas for each of the BalancerTargets.

Jump to

Keyboard shortcuts

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