Documentation ¶
Index ¶
- func Module() fx.Option
- func NewPodScalerOptions(podScalerProto *policylangv1.PodScaler, componentStackID string, ...) (fx.Option, string, error)
- func NewScaleActuatorAndOptions(scaleActuatorProto *policylangv1.PodScaler_ScaleActuator, componentID string, ...) (runtime.Component, fx.Option, error)
- func NewScaleReporterAndOptions(_ *policylangv1.PodScaler_ScaleReporter, componentID string, ...) (runtime.Component, fx.Option, error)
- type ScaleActuator
- func (sa *ScaleActuator) DynamicConfigUpdate(event notifiers.Event, unmarshaller config.Unmarshaller)
- func (sa *ScaleActuator) Execute(inPortReadings runtime.PortToReading, tickInfo runtime.TickInfo) (runtime.PortToReading, error)
- func (*ScaleActuator) IsActuator() bool
- func (*ScaleActuator) Name() string
- func (sa *ScaleActuator) ShortDescription() string
- func (*ScaleActuator) Type() runtime.ComponentType
- type ScaleReporter
- func (sr *ScaleReporter) DynamicConfigUpdate(event notifiers.Event, unmarshaller config.Unmarshaller)
- func (sr *ScaleReporter) Execute(inPortReadings runtime.PortToReading, tickInfo runtime.TickInfo) (runtime.PortToReading, error)
- func (*ScaleReporter) IsActuator() bool
- func (*ScaleReporter) Name() string
- func (sr *ScaleReporter) ShortDescription() string
- func (sr *ScaleReporter) Type() runtime.ComponentType
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewPodScalerOptions ¶
func NewPodScalerOptions( podScalerProto *policylangv1.PodScaler, componentStackID string, policyReadAPI iface.Policy, ) (fx.Option, string, error)
NewPodScalerOptions creates fx options for HorizontalPodScaler and also returns the agent group name associated with it.
func NewScaleActuatorAndOptions ¶
func NewScaleActuatorAndOptions( scaleActuatorProto *policylangv1.PodScaler_ScaleActuator, componentID string, policyReadAPI iface.Policy, agentGroup string, ) (runtime.Component, fx.Option, error)
NewScaleActuatorAndOptions creates scale actuator and its fx options.
func NewScaleReporterAndOptions ¶
func NewScaleReporterAndOptions( _ *policylangv1.PodScaler_ScaleReporter, componentID string, policyReadAPI iface.Policy, agentGroup string, ) (runtime.Component, fx.Option, error)
NewScaleReporterAndOptions returns a new ScaleReporter and its fx options.
Types ¶
type ScaleActuator ¶
type ScaleActuator struct {
// contains filtered or unexported fields
}
ScaleActuator struct.
func (*ScaleActuator) DynamicConfigUpdate ¶
func (sa *ScaleActuator) DynamicConfigUpdate(event notifiers.Event, unmarshaller config.Unmarshaller)
DynamicConfigUpdate finds the dynamic config and syncs the decision to agent.
func (*ScaleActuator) Execute ¶
func (sa *ScaleActuator) Execute(inPortReadings runtime.PortToReading, tickInfo runtime.TickInfo) (runtime.PortToReading, error)
Execute implements runtime.Component.Execute.
func (*ScaleActuator) IsActuator ¶ added in v1.1.0
func (*ScaleActuator) IsActuator() bool
IsActuator implements runtime.Component.
func (*ScaleActuator) ShortDescription ¶
func (sa *ScaleActuator) ShortDescription() string
ShortDescription implements runtime.Component.
func (*ScaleActuator) Type ¶
func (*ScaleActuator) Type() runtime.ComponentType
Type implements runtime.Component.
type ScaleReporter ¶
type ScaleReporter struct {
// contains filtered or unexported fields
}
ScaleReporter struct.
func (*ScaleReporter) DynamicConfigUpdate ¶
func (sr *ScaleReporter) DynamicConfigUpdate(event notifiers.Event, unmarshaller config.Unmarshaller)
DynamicConfigUpdate is a no-op for this component.
func (*ScaleReporter) Execute ¶
func (sr *ScaleReporter) Execute(inPortReadings runtime.PortToReading, tickInfo runtime.TickInfo) (runtime.PortToReading, error)
Execute implements runtime.Component.
func (*ScaleReporter) IsActuator ¶ added in v1.1.0
func (*ScaleReporter) IsActuator() bool
IsActuator implements runtime.Component.
func (*ScaleReporter) Name ¶
func (*ScaleReporter) Name() string
Name implements runtime.Component.Name.
func (*ScaleReporter) ShortDescription ¶
func (sr *ScaleReporter) ShortDescription() string
ShortDescription implements runtime.Component.ShortDescription.
func (*ScaleReporter) Type ¶
func (sr *ScaleReporter) Type() runtime.ComponentType
Type implements runtime.Component.Type.