Documentation
¶
Index ¶
- type ModelScaler
- func (s *ModelScaler) ListAllModels(ctx context.Context) ([]kubeaiv1.Model, error)
- func (s *ModelScaler) ModelExists(ctx context.Context, model string) (bool, error)
- func (s *ModelScaler) Scale(ctx context.Context, model *kubeaiv1.Model, replicas int32, ...) error
- func (s *ModelScaler) ScaleAtLeastOneReplica(ctx context.Context, model string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ModelScaler ¶
type ModelScaler struct {
// contains filtered or unexported fields
}
func NewModelScaler ¶
func NewModelScaler(client client.Client, namespace string) *ModelScaler
func (*ModelScaler) ListAllModels ¶
func (*ModelScaler) ModelExists ¶
func (*ModelScaler) Scale ¶
func (s *ModelScaler) Scale(ctx context.Context, model *kubeaiv1.Model, replicas int32, requiredConsecutiveScaleDowns int) error
Scale scales the model to the desired number of replicas, enforcing the min and max replica bounds. Model should have .Spec defined before calling Scale().
func (*ModelScaler) ScaleAtLeastOneReplica ¶
func (s *ModelScaler) ScaleAtLeastOneReplica(ctx context.Context, model string) error
Click to show internal directories.
Click to hide internal directories.