Documentation ¶
Index ¶
- type ScalerBuilder
- type ScalersCache
- func (c *ScalersCache) Close(ctx context.Context)
- func (c *ScalersCache) GetMetricSpecForScaling(ctx context.Context) []v2.MetricSpec
- func (c *ScalersCache) GetMetricsForScaler(ctx context.Context, index int, metricName string) ([]external_metrics.ExternalMetricValue, error)
- func (c *ScalersCache) GetPushScalers() []scalers.PushScaler
- func (c *ScalersCache) GetScaledObjectState(ctx context.Context, scaledObject *kedav1alpha1.ScaledObject) (bool, bool, map[string]metricscache.MetricsRecord)
- func (c *ScalersCache) GetScalers() ([]scalers.Scaler, []scalers.ScalerConfig)
- func (c *ScalersCache) IsScaledJobActive(ctx context.Context, scaledJob *kedav1alpha1.ScaledJob) (bool, int64, int64)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ScalerBuilder ¶
type ScalerBuilder struct { Scaler scalers.Scaler ScalerConfig scalers.ScalerConfig Factory func() (scalers.Scaler, *scalers.ScalerConfig, error) }
type ScalersCache ¶
type ScalersCache struct { ScaledObject *kedav1alpha1.ScaledObject Scalers []ScalerBuilder ScalableObjectGeneration int64 Recorder record.EventRecorder }
func (*ScalersCache) Close ¶
func (c *ScalersCache) Close(ctx context.Context)
func (*ScalersCache) GetMetricSpecForScaling ¶
func (c *ScalersCache) GetMetricSpecForScaling(ctx context.Context) []v2.MetricSpec
func (*ScalersCache) GetMetricsForScaler ¶
func (c *ScalersCache) GetMetricsForScaler(ctx context.Context, index int, metricName string) ([]external_metrics.ExternalMetricValue, error)
GetMetricsForScaler returns metric value for a scaler identified by the metric name and by the input index (from the list of scalers in this ScaledObject)
func (*ScalersCache) GetPushScalers ¶
func (c *ScalersCache) GetPushScalers() []scalers.PushScaler
func (*ScalersCache) GetScaledObjectState ¶ added in v2.9.0
func (c *ScalersCache) GetScaledObjectState(ctx context.Context, scaledObject *kedav1alpha1.ScaledObject) (bool, bool, map[string]metricscache.MetricsRecord)
GetScaledObjectState returns whether the input ScaledObject is active as a first parameters, the second parameter indicates whether there was any error during quering scalers the third parameter returns map of metrics record - a metric value for each scaler and it's metric
func (*ScalersCache) GetScalers ¶
func (c *ScalersCache) GetScalers() ([]scalers.Scaler, []scalers.ScalerConfig)
func (*ScalersCache) IsScaledJobActive ¶
func (c *ScalersCache) IsScaledJobActive(ctx context.Context, scaledJob *kedav1alpha1.ScaledJob) (bool, int64, int64)
Click to show internal directories.
Click to hide internal directories.