Skip to content

Commit

Permalink
Fix targeted scale-in logic (#215)
Browse files Browse the repository at this point in the history
* reset priority of machines with no deletion taint to 3

* run hack/update-gofmt.sh

* address review comments and refactor DeleteMachines method

* address review comments part 2

* address review comments part 3

* remove time.Sleep from mcm_manager.go

* added timeouts to mcmManager struct for testing

* initial changes for testing framework

* minor refactoring of mcm cloudprovider implementation

* refactor fakingOptions in fake client

* introduce unit tests for DeleteNodes method

* vendor changes

* resolve linting errors

* remove race conditions

* remove race conditions part-2

* address review comments part-1

* remove deadline for cache get/list calls

* update for-go-proj.sh to run only mcm tests in cloudprovider

* update doc string

* address review comments

* address review comments part-2

* move reset priority logic to refresh method

* address review comments part-3

* address review comments part-4

* address review comments part-5

* return collective error for priority reset of machines
  • Loading branch information
rishabh-11 authored Aug 17, 2023
1 parent a202aab commit abc1666
Show file tree
Hide file tree
Showing 21 changed files with 2,465 additions and 232 deletions.
9 changes: 5 additions & 4 deletions cluster-autoscaler/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -116,9 +116,10 @@ start:
@GO111MODULE=on go run main.go \
--kubeconfig=$(TARGET_KUBECONFIG) \
--cloud-provider=mcm \
--nodes=1:2:$(MACHINE_DEPLOYMENT_ZONE_1) \
--nodes=0:1:$(MACHINE_DEPLOYMENT_ZONE_2) \
--nodes=0:1:$(MACHINE_DEPLOYMENT_ZONE_3) \
--nodes=0:2:$(MACHINE_DEPLOYMENT_1_ZONE_1) \
--nodes=1:2:$(MACHINE_DEPLOYMENT_2_ZONE_1) \
--nodes=0:1:$(MACHINE_DEPLOYMENT_2_ZONE_2) \
--nodes=0:1:$(MACHINE_DEPLOYMENT_2_ZONE_3) \
--skip-nodes-with-system-pods=false \
--skip-nodes-with-local-storage=false \
--scale-down-delay-after-add=10s \
Expand Down Expand Up @@ -147,7 +148,7 @@ download-kubeconfigs:
read SHOOT; \
echo "enter cluster provider(gcp|aws|azure|vsphere|openstack|alicloud|metal|equinix-metal)"; \
read PROVIDER; \
echo "enter zone with zero nodes where the PV needs to be created to perform test"; \
echo "enter zone with zero nodes in worker pool \"three-zones\" where the PV needs to be created to perform test"; \
read ZONE; \
. ./hack/local_setup.sh --SEED $$SEED --SHOOT $$SHOOT --PROJECT $$PROJECT; \
echo "###############################################" ; \
Expand Down
Loading

0 comments on commit abc1666

Please sign in to comment.