Documentation
¶
Index ¶
- func CreateOrUpdateVpaCheckpoint(vpaCheckpointClient vpa_api.VerticalPodAutoscalerCheckpointInterface, ...) error
- func GetContainerControlledValues(name string, vpaResourcePolicy *vpa_types.PodResourcePolicy) vpa_types.ContainerControlledValues
- func GetContainerResourcePolicy(containerName string, policy *vpa_types.PodResourcePolicy) *vpa_types.ContainerResourcePolicy
- func GetUpdateMode(vpa *vpa_types.VerticalPodAutoscaler) vpa_types.UpdateMode
- func NewVpasLister(vpaClient *vpa_clientset.Clientset, stopChannel <-chan struct{}, ...) vpa_lister.VerticalPodAutoscalerLister
- func UpdateVpaStatusIfNeeded(vpaClient vpa_api.VerticalPodAutoscalerInterface, vpaName string, ...) (result *vpa_types.VerticalPodAutoscaler, err error)
- type ContainerToAnnotationsMap
- type RecommendationProcessor
- type VpaWithSelector
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateOrUpdateVpaCheckpoint ¶
func CreateOrUpdateVpaCheckpoint(vpaCheckpointClient vpa_api.VerticalPodAutoscalerCheckpointInterface, vpaCheckpoint *vpa_types.VerticalPodAutoscalerCheckpoint) error
func GetContainerControlledValues ¶
func GetContainerControlledValues(name string, vpaResourcePolicy *vpa_types.PodResourcePolicy) vpa_types.ContainerControlledValues
func GetContainerResourcePolicy ¶
func GetContainerResourcePolicy(containerName string, policy *vpa_types.PodResourcePolicy) *vpa_types.ContainerResourcePolicy
func GetUpdateMode ¶
func GetUpdateMode(vpa *vpa_types.VerticalPodAutoscaler) vpa_types.UpdateMode
func NewVpasLister ¶
func NewVpasLister(vpaClient *vpa_clientset.Clientset, stopChannel <-chan struct{}, namespace string) vpa_lister.VerticalPodAutoscalerLister
func UpdateVpaStatusIfNeeded ¶
func UpdateVpaStatusIfNeeded(vpaClient vpa_api.VerticalPodAutoscalerInterface, vpaName string, newStatus, oldStatus *vpa_types.VerticalPodAutoscalerStatus) (result *vpa_types.VerticalPodAutoscaler, err error)
Types ¶
type ContainerToAnnotationsMap ¶
ContainerToAnnotationsMap contains annotations per container.
type RecommendationProcessor ¶
type RecommendationProcessor interface {
// Apply processes and updates recommendation for given pod, based on container limits,
// VPA policy and possibly other internal RecommendationProcessor context.
// Must return a non-nil pointer to RecommendedPodResources or error.
Apply(podRecommendation *vpa_types.RecommendedPodResources,
policy *vpa_types.PodResourcePolicy,
conditions []vpa_types.VerticalPodAutoscalerCondition,
pod *v1.Pod) (*vpa_types.RecommendedPodResources, ContainerToAnnotationsMap, error)
}
RecommendationProcessor post-processes recommendation adjusting it to limits and environment context
func NewCappingRecommendationProcessor ¶
func NewCappingRecommendationProcessor(limitsRangeCalculator limitrange.LimitRangeCalculator) RecommendationProcessor
type VpaWithSelector ¶
type VpaWithSelector struct {
Vpa *vpa_types.VerticalPodAutoscaler
Selector labels.Selector
}
VpaWithSelector is a pair of VPA and its selector.
func GetControllingVPAForPod ¶
func GetControllingVPAForPod(pod *core.Pod, vpas []*VpaWithSelector) *VpaWithSelector
Click to show internal directories.
Click to hide internal directories.