Skip to content

Commit

Permalink
💄 Remove deprecated 'NewScheduler' func
Browse files Browse the repository at this point in the history
Signed-off-by: Matthias Wessendorf <[email protected]>
  • Loading branch information
matzew committed Sep 4, 2023
1 parent d532005 commit e1f5284
Showing 1 changed file with 0 additions and 30 deletions.
30 changes: 0 additions & 30 deletions pkg/scheduler/statefulset/scheduler.go
Original file line number Diff line number Diff line change
Expand Up @@ -110,36 +110,6 @@ func New(ctx context.Context, cfg *Config) (scheduler.Scheduler, error) {
return s, nil
}

// NewScheduler creates a new scheduler with pod autoscaling enabled.
// Deprecated: Use New
func NewScheduler(ctx context.Context,
namespace, name string,
lister scheduler.VPodLister,
refreshPeriod time.Duration,
capacity int32,
schedulerPolicy scheduler.SchedulerPolicyType,
nodeLister corev1listers.NodeLister,
evictor scheduler.Evictor,
schedPolicy *scheduler.SchedulerPolicy,
deschedPolicy *scheduler.SchedulerPolicy) scheduler.Scheduler {

cfg := &Config{
StatefulSetNamespace: namespace,
StatefulSetName: name,
PodCapacity: capacity,
RefreshPeriod: refreshPeriod,
SchedulerPolicy: schedulerPolicy,
SchedPolicy: schedPolicy,
DeschedPolicy: deschedPolicy,
Evictor: evictor,
VPodLister: lister,
NodeLister: nodeLister,
}

s, _ := New(ctx, cfg)
return s
}

type Pending map[types.NamespacedName]int32

func (p Pending) Total() int32 {
Expand Down

0 comments on commit e1f5284

Please sign in to comment.