Documentation ¶
Index ¶
- func NewHPARecommender(recommender apis.Recommender, ...) (recommender.Recommender, error)
- type HPARecommender
- func (rr *HPARecommender) CheckDataProviders(ctx *framework.RecommendationContext) error
- func (rr *HPARecommender) CollectData(ctx *framework.RecommendationContext) error
- func (rr *HPARecommender) Filter(ctx *framework.RecommendationContext) error
- func (rr *HPARecommender) Name() string
- func (rr *HPARecommender) Observe(ctx *framework.RecommendationContext) error
- func (rr *HPARecommender) Policy(ctx *framework.RecommendationContext) error
- func (rr *HPARecommender) PostProcessing(ctx *framework.RecommendationContext) error
- func (rr *HPARecommender) PreRecommend(ctx *framework.RecommendationContext) error
- func (rr *HPARecommender) Recommend(ctx *framework.RecommendationContext) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewHPARecommender ¶
func NewHPARecommender(recommender apis.Recommender, recommendationRule analysisv1alph1.RecommendationRule) (recommender.Recommender, error)
NewHPARecommender create a new hpa recommender.
Types ¶
type HPARecommender ¶
type HPARecommender struct { replicas.ReplicasRecommender PredictableEnabled bool ReferenceHpaEnabled bool MinCpuUsageThreshold float64 FluctuationThreshold float64 MinCpuTargetUtilization int64 MaxCpuTargetUtilization int64 MaxReplicasFactor float64 }
func (*HPARecommender) CheckDataProviders ¶
func (rr *HPARecommender) CheckDataProviders(ctx *framework.RecommendationContext) error
CheckDataProviders in PrePrepare phase, will create data source provider via your recommendation config.
func (*HPARecommender) CollectData ¶
func (rr *HPARecommender) CollectData(ctx *framework.RecommendationContext) error
func (*HPARecommender) Filter ¶
func (rr *HPARecommender) Filter(ctx *framework.RecommendationContext) error
Filter out k8s resources that are not supported by the recommender.
func (*HPARecommender) Name ¶
func (rr *HPARecommender) Name() string
func (*HPARecommender) Observe ¶
func (rr *HPARecommender) Observe(ctx *framework.RecommendationContext) error
Observe enhance the observability.
func (*HPARecommender) Policy ¶
func (rr *HPARecommender) Policy(ctx *framework.RecommendationContext) error
Policy add some logic for result of recommend phase.
func (*HPARecommender) PostProcessing ¶
func (rr *HPARecommender) PostProcessing(ctx *framework.RecommendationContext) error
func (*HPARecommender) PreRecommend ¶
func (rr *HPARecommender) PreRecommend(ctx *framework.RecommendationContext) error
func (*HPARecommender) Recommend ¶
func (rr *HPARecommender) Recommend(ctx *framework.RecommendationContext) error
Click to show internal directories.
Click to hide internal directories.