File tree Expand file tree Collapse file tree 2 files changed +1
-27
lines changed Expand file tree Collapse file tree 2 files changed +1
-27
lines changed Original file line number Diff line number Diff line change @@ -178,7 +178,7 @@ func NewTestProcessors(context *context.AutoscalingContext) *processors.Autoscal
178
178
return & processors.AutoscalingProcessors {
179
179
PodListProcessor : podlistprocessor .NewDefaultPodListProcessor (context .PredicateChecker ),
180
180
NodeGroupListProcessor : & nodegroups.NoOpNodeGroupListProcessor {},
181
- BinpackingLimiter : binpacking .NewDefaultBinpackingLimiter ( ),
181
+ BinpackingLimiter : binpacking .NewTimeLimiter ( context . MaxNodeGroupBinpackingDuration ),
182
182
NodeGroupSetProcessor : nodegroupset .NewDefaultNodeGroupSetProcessor ([]string {}, config.NodeGroupDifferenceRatios {}),
183
183
ScaleDownSetProcessor : nodes .NewCompositeScaleDownSetProcessor ([]nodes.ScaleDownSetProcessor {
184
184
nodes .NewMaxNodesProcessor (),
Original file line number Diff line number Diff line change @@ -29,29 +29,3 @@ type BinpackingLimiter interface {
29
29
StopBinpacking (context * context.AutoscalingContext , evaluatedOptions []expander.Option ) bool
30
30
FinalizeBinpacking (context * context.AutoscalingContext , finalOptions []expander.Option )
31
31
}
32
-
33
- // NoOpBinpackingLimiter returns true without processing expansion options.
34
- type NoOpBinpackingLimiter struct {
35
- }
36
-
37
- // NewDefaultBinpackingLimiter creates an instance of NoOpBinpackingLimiter.
38
- func NewDefaultBinpackingLimiter () BinpackingLimiter {
39
- return & NoOpBinpackingLimiter {}
40
- }
41
-
42
- // InitBinpacking initialises the BinpackingLimiter.
43
- func (p * NoOpBinpackingLimiter ) InitBinpacking (context * context.AutoscalingContext , nodeGroups []cloudprovider.NodeGroup ) {
44
- }
45
-
46
- // MarkProcessed marks the nodegroup as processed.
47
- func (p * NoOpBinpackingLimiter ) MarkProcessed (context * context.AutoscalingContext , nodegroupId string ) {
48
- }
49
-
50
- // StopBinpacking is used to make decsions on the evaluated expansion options.
51
- func (p * NoOpBinpackingLimiter ) StopBinpacking (context * context.AutoscalingContext , evaluatedOptions []expander.Option ) bool {
52
- return false
53
- }
54
-
55
- // FinalizeBinpacking is called to finalize the BinpackingLimiter.
56
- func (p * NoOpBinpackingLimiter ) FinalizeBinpacking (context * context.AutoscalingContext , finalOptions []expander.Option ) {
57
- }
You can’t perform that action at this time.
0 commit comments