Commit Graph
195 Commits
Author SHA1 Message Date
Kubernetes Prow Robot 112684bcb9 Merge pull request #181 from jw-s/feature/respect-tolerations
Respect Node taints with tolerations (if exist)
2020-03-04 10:45:48 -08:00
Jan Chaloupka 9593ce16d9 List nodes through informer in every iteration
Also, refactor the code a bit so it can be tested without checking for eviction support.
2020-03-04 16:26:13 +01:00
Joel Whittaker-Smith 4757132452 check for taints on low nodes and honor them 2020-03-02 14:43:11 +01:00
Avesh Agarwal 8dc7b475d9 Fix makefile for make gen, and Update hack files and
auto-generated files.
2020-02-07 16:32:55 -05:00
Kubernetes Prow Robot fc8c581d7a Merge pull request #226 from ankon/pr/node-unschedulable-typo
Fix typo in function name
2020-02-07 08:13:47 -08:00
Jan Chaloupka d065f9904b Critical pod annotation scheduler.alpha.kubernetes.io/critical-pod has been drop, no need to set it anymore in the tests 2020-02-07 16:29:44 +01:00
Andreas Kohn c3346e9806 Fix typo in function name 2020-02-04 10:03:08 +01:00
Mike Dame 816f8cb682 Fix build errors 2020-02-03 10:05:04 -05:00
Mike Dame 431597dd43 Break dependency on k8s.io/kubernetes 2020-02-03 10:04:53 -05:00
Mike Dame 30d05382b6 Wire --descheduler-interval flag to run descheduler on a loop 2020-01-30 17:17:55 -05:00
Sean Malloy e3d06d1541 Create k8s event when a pod is successfully evicted
This allows end users to more easily monitor when the descheduler evicts
a pod in their environment. Prior to adding k8s event support the only
way to track evicted pods was to view the logs.
2019-12-11 21:35:57 -06:00
Zhang Jinghui 872953b9cf normalize blank import 2019-11-09 21:53:29 +08:00
swatisehgal 7563b5561b Strategy to consider taints and tolerations in Descheduler 2019-11-05 20:42:36 +00:00
Mike Dame 4b9e732c18 Switch from glog to klog 2019-10-28 20:44:02 -04:00
Kubernetes Prow Robot dd54f1a656 Merge pull request #188 from damemi/k8s-1.16
Bump to k8s 1.16
2019-10-22 09:07:22 -07:00
Mike Dame 11044ed89d Run generated scripts 2019-10-21 13:33:39 -04:00
Mike Dame c9e3c63b85 Remove codecgen
Since [1] codecgen has been obsolete.

[1] https://github.com/kubernetes/kubernetes/issues/36120
2019-10-21 13:33:38 -04:00
Mike Dame b176dd2e77 Remove old NodeOutOfDisk unit test 2019-10-21 13:33:38 -04:00
Mike Dame 9ea6aa536e Update CriticalPod unit test
The kubelet used to only determine critical pods by the namespace and an annotation (see [1], where our code switched from only checking the annotation to using the kubelet package helper, which at that revision also only checked for an annotation and namespace). However, now the kubelet uses Pod Priority to check for critical pods[3], which is controlled by an admission plugin[4]. Given that testing the functioning of the admission plugin is out of the scope of this repository, it is probably sufficient to manually set the pod priority to critical, to ensure that our Descheduler code behaves properly in response.

[1] https://github.com/kubernetes-sigs/descheduler/commit/062b8698c73120d4469c74b9894c962d9a5ea552#diff-094ac8507e224603239ce19592b518f5
[2] https://github.com/kubernetes/kubernetes/blob/release-1.9/pkg/kubelet/types/pod_update.go#L151
[3] https://github.com/kubernetes/kubernetes/blob/a847874655/pkg/kubelet/types/pod_update.go#L153
[4] https://github.com/kubernetes/kubernetes/blob/a847874655/plugin/pkg/admission/priority/admission.go
2019-10-21 13:33:38 -04:00
sph 5e25e21ca2 Fix golint errors
Signed-off-by: sph <shepenghui1@huawei.com>
2019-10-17 20:50:13 +08:00
Mike Dame 0af97c1b5e fix compile errors 2019-10-12 11:12:04 -04:00
Mike Dame 5af668e89a Remove old API install patterns 2019-10-12 11:08:46 -04:00
Mike Dame 26adf87323 Bump reactions
Change imports to reflect current component-base usage
2019-10-12 11:07:21 -04:00
ksimon1 fb1b5fc690 added unit test
updated e2e test

Signed-off-by: ksimon1 <ksimon@redhat.com>
2019-10-04 11:08:33 +02:00
ksimon1 dc7f9efc19 Descheduler can evict all types of pods with special annotation
When pod has this annotation, descheduler will always try to evict this pod.
User can control which pods (only pods with this annotation) will be evicted.
Signed-off-by: ksimon1 <ksimon@redhat.com>
2019-10-04 11:07:40 +02:00
Jan Chaloupka e35eb4a0b5 Run ./hack/update-gofmt 2019-09-19 14:29:00 +02:00
Jan Chaloupka 2e6f14103b Project migrared under kubernetes-sigs, change import path prefix to sigs.k8s.io/descheduler 2019-09-19 14:09:05 +02:00
Dane De Forest cd4d09726c Fix small typo in output for thresholds for low utilization 2019-08-28 11:25:55 -07:00
Sebastiaan Tammer 20c610c65a Improved logic for duplicates testing 2019-06-11 20:35:55 +02:00
Reeta Singh dee89a6cc1 Refactoring test by make it table driven and adding golangci-lint to the CI pipeline 2019-06-03 20:40:02 -07:00
Sebastiaan Tammer 023a2f2a47 Replaced UID with Namespace for duplicate check, added tests (+ cleanup) 2019-05-25 11:18:11 +02:00
Sebastiaan Tammer d1c6f3f709 Added ownerRef.UID for evaluating duplicate Pods 2019-05-24 18:51:33 +02:00
Adi Yadav e6e200b93c Added auto-generated changes. 2019-04-11 23:24:56 -04:00
Adi Yadav 5d843d1f08 Added manual changes. 2019-04-11 23:24:20 -04:00
ravisantoshgudimetla a079fd2757 Remove the unnecessary print statements 2018-08-22 11:27:40 -04:00
ravisantoshgudimetla d0305dac3f Low node utilization to respect priority while evicting pods 2018-08-21 14:14:26 -04:00
Hugues Alary 450a5c290b Allow other auth providers (GCP, OIDC, Azure, OpenStack) 2018-05-22 19:13:47 -07:00
Avesh Agarwal 57a28e9a8f Fix dryRun issue and avoid unnecessary log
msg when node affinity strategy is disabled.
2018-04-23 17:13:19 -04:00
Avesh Agarwal 34fb602101 Fix max pods to evict per node. 2018-04-12 15:28:24 -04:00
Jan Chaloupka f7d0acb731 Regen 2018-03-22 12:40:23 +01:00
ravisantoshgudimetla f1f8b2eaa7 Limit maximum number of pods to be evicted per node 2018-03-22 12:40:19 +01:00
Shubham Minglani bb25192163 add generated files 2018-02-19 16:21:04 +05:30
Shubham Minglani 40bb490f4c add RemovePodsViolatingNodeAffinity strategy
This commit adds requiredDuringSchedulingIgnoredDuringExecution
for RemovePodsViolatingNodeAffinity strategy.

Also adds unit tests and documentation.
2018-02-19 16:20:59 +05:30
ravisantoshgudimetla ba3eac6c57 Descheduler should not run when cluster size is 1 2018-02-08 21:15:02 -05:00
Avesh Agarwal 44752e5e83 Update code and hack dir for kube 1.9 rebase. 2018-01-09 12:41:01 -05:00
Avesh Agarwal 7123f30783 Update auto-generated code. 2018-01-09 11:04:26 -05:00
ravisantoshgudimetla bf29a6073f Owner ref switch
Signed-off-by: ravisantoshgudimetla <ravisantoshgudimetla@gmail.com>
2018-01-05 00:22:12 +05:30
ravisantoshgudimetla 6f873d5e69 Make GPU requested pods not evictable by descheduler 2017-12-05 03:49:47 -05:00
Avesh Agarwal 445ae92caa Merge pull request #59 from aveshagarwal/master-fix-errors
Update logging and a few fixes.
2017-12-01 13:19:36 -05:00
Avesh Agarwal 8f3c0cf4b8 Merge pull request #58 from aveshagarwal/master-fix-node-lister
Fix node lister by allowing its reflector to have enough time so that listing works.
2017-12-01 13:02:17 -05:00