Documentation ¶
Index ¶
- func New(ctx context.Context, cfg *Config) (scheduler.Scheduler, error)
- type Autoscaler
- type Config
- type GetReserved
- type Pending
- type StatefulSetScheduler
- func (s *StatefulSetScheduler) Demote(b reconciler.Bucket)
- func (s *StatefulSetScheduler) Promote(b reconciler.Bucket, enq func(reconciler.Bucket, types.NamespacedName)) error
- func (s *StatefulSetScheduler) Reserved() map[types.NamespacedName]map[string]int32
- func (s *StatefulSetScheduler) Schedule(ctx context.Context, vpod scheduler.VPod) ([]duckv1alpha1.Placement, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Autoscaler ¶
type Config ¶ added in v0.35.6
type Config struct { StatefulSetNamespace string `json:"statefulSetNamespace"` StatefulSetName string `json:"statefulSetName"` ScaleCacheConfig scheduler.ScaleCacheConfig `json:"scaleCacheConfig"` // PodCapacity max capacity for each StatefulSet's pod. PodCapacity int32 `json:"podCapacity"` // MinReplicas is the minimum replicas of the statefulset. MinReplicas int32 `json:"minReplicas"` // Autoscaler refresh period RefreshPeriod time.Duration `json:"refreshPeriod"` // Autoscaler retry period RetryPeriod time.Duration `json:"retryPeriod"` Evictor scheduler.Evictor `json:"-"` VPodLister scheduler.VPodLister `json:"-"` // Pod lister for statefulset: StatefulSetNamespace / StatefulSetName PodLister corev1listers.PodNamespaceLister `json:"-"` // contains filtered or unexported fields }
type GetReserved ¶ added in v0.38.2
type GetReserved func() map[types.NamespacedName]map[string]int32
type Pending ¶ added in v0.38.2
type Pending map[types.NamespacedName]int32
type StatefulSetScheduler ¶
type StatefulSetScheduler struct {
// contains filtered or unexported fields
}
StatefulSetScheduler is a scheduler placing VPod into statefulset-managed set of pods
func (*StatefulSetScheduler) Demote ¶ added in v0.37.0
func (s *StatefulSetScheduler) Demote(b reconciler.Bucket)
Demote implements reconciler.LeaderAware.
func (*StatefulSetScheduler) Promote ¶ added in v0.37.0
func (s *StatefulSetScheduler) Promote(b reconciler.Bucket, enq func(reconciler.Bucket, types.NamespacedName)) error
Promote implements reconciler.LeaderAware.
func (*StatefulSetScheduler) Reserved ¶ added in v0.38.2
func (s *StatefulSetScheduler) Reserved() map[types.NamespacedName]map[string]int32
func (*StatefulSetScheduler) Schedule ¶
func (s *StatefulSetScheduler) Schedule(ctx context.Context, vpod scheduler.VPod) ([]duckv1alpha1.Placement, error)
Click to show internal directories.
Click to hide internal directories.