Sean Malloy
6f7e2a271e
Update e2e tests to use kind v0.10.0
2021-02-25 00:17:06 -06:00
Mike Dame
c1a63a557a
Add option to ignore pods with PVCs from eviction
2021-01-26 08:47:54 -05:00
wu.chaozong
1a998037f8
refactor: remove unuse param in e2e_test.go
2020-12-16 08:46:40 +08:00
Ali Farah
3ac0c408de
Add --logging-format flag
...
Add k8s.io/component-base/config package
2020-10-12 22:27:39 +11:00
Sean Malloy
d7420eb945
Update e2e tests to use kind v0.9.0
2020-09-15 09:11:36 -05:00
lixiang
1303fe6eb9
PodLifeTime: allow custom podStatusPhases
2020-09-11 09:56:45 +08:00
Sean Malloy
1fb3445692
Fix golangci-lint Failures For 1.30.0 Upgrade
2020-08-31 14:03:43 -05:00
Jan Chaloupka
d8251b9086
Redefine IsEvictable to be customizable for a particular strategy
...
Use WithXXX methods to extend the list of constraints to also
provide a reasonable error message.
2020-08-19 11:21:26 +02:00
Jan Chaloupka
a7c51ffae0
Promote Namespaces field to a pointer
2020-08-13 18:38:46 +02:00
lixiang
6d693d06fb
e2e: add testcase for priority threshold
2020-08-12 13:55:53 +08:00
lixiang
4d7a6ee9be
e2e: Add priority and priority class to runPodLifetimeStrategy and RcByNameContainer
2020-08-12 13:55:53 +08:00
lixiang
95ce2a4ff7
PodEvictor: add a new param thresholdPriority to IsEvictable
2020-08-11 09:57:26 +08:00
Jan Chaloupka
c40a9c397f
e2e: add test for included/excluded namespace through PodLifeTime strategy
2020-07-27 10:54:35 +02:00
Jan Chaloupka
74f70fdbc9
ListPodsOnANode: define Options type to pass various options
...
Options like:
- filter
- included/excluded namespaces
- labels
2020-07-21 15:07:45 +02:00
Kubernetes Prow Robot
0894f7740c
Merge pull request #343 from ingvagabund/test-cleanup
...
Clean e2e test so it's easier to extend it
2020-07-21 05:21:13 -07:00
Jan Chaloupka
53badf7b61
e2e: create dedicated ns for each e2e test
2020-07-17 18:15:53 +02:00
Jan Chaloupka
f801c5f72f
e2e: code cleanup
2020-07-17 18:15:13 +02:00
Jan Chaloupka
327880ba51
e2e: separate tests for LowNodeUtilization strategy and evict annotation
2020-07-17 18:11:01 +02:00
Jan Chaloupka
7bb8b4feda
e2e: create and delete RC in the same function body
...
So create/delete are coupled and caller of create is responsible for calling delete as well
2020-07-17 18:06:19 +02:00
Jan Chaloupka
5761b5d595
e2e: have k8s version configurable when creating cluster through kind
2020-07-14 15:25:02 +02:00
Mike Dame
f5e9f07321
Move kind setup to e2e script
...
This moves the kind setup (previously used by Travis) to the e2e runner script
to accomodate the switch to Prow. This provides a KIND_E2E env var to specify
whether to run the tests in kind, or (by default) to run locally).
2020-07-13 15:49:41 -04:00
Kubernetes Prow Robot
267b0837dc
Merge pull request #327 from farah/farah/klog-migration
...
Update klog to v2
2020-06-23 08:35:40 -07:00
Ali Farah
15fcde5229
Update klog to v2
2020-06-22 20:43:22 +10:00
lixiang
7457626f62
Move helper funcs to testutil
2020-06-16 19:17:28 +08:00
Mike Dame
f5e4acdd8a
Make evictLocalStoragePods a property of PodEvictor
...
This is a minor refactor of PodEvictor to include evictLocalStoragePods as a
property (so that it doesn't need to be passed to each strategy function.) It
also removes ListEvictablePodsOnNode and extends ListPodsOnANode with an optional
"filter" function parameter, so that for example IsEvictable can be passed to it
and achieve the same results as the function formerly known as ListEvictablePodsOnNode.
This approach also now allows strategies to more explicitly extend their criteria of what
IsEvictable considers an evictable pod (such as NodeAffinity, which checks that the pod
can fit on any other node).
2020-06-05 10:28:48 -04:00
Jan Chaloupka
5a81a0661b
Make DeschedulerStrategy.Params a pointer
...
To avoid empty params fields when serializing:
RemoveDuplicates:
enabled: true
params: {}
RemovePodsHavingTooManyRestarts:
enabled: true
params:
podsHavingTooManyRestarts: {}
RemovePodsViolatingInterPodAntiAffinity:
enabled: true
params: {}
RemovePodsViolatingNodeAffinity:
enabled: true
params:
nodeAffinityType:
- requiredDuringSchedulingIgnoredDuringExecution
RemovePodsViolatingNodeTaints:
enabled: true
params: {}
2020-05-27 10:31:31 +02:00
Mike Dame
eec1104d6e
React to 1.18 by adding contexts to client calls
2020-05-12 15:01:25 -04:00
Jan Chaloupka
cbcefb5d2f
Remove options.DeschedulerServer from all strategies
2020-04-28 16:13:33 +02:00
Jan Chaloupka
991eddb691
Turn StrategyParameters.NodeResourceUtilizationThresholds field into a pointer
...
The field is intended to be omitempty when not set. Without a pointer the strategy
serialized into json string looks like:
```json
strategies:
LowNodeUtilization:
enabled: true
params:
nodeResourceUtilizationThresholds:
numberOfNodes: 1
targetThresholds:
cpu: 50
memory: 50
pods: 20
thresholds:
cpu: 50
memory: 50
pods: 20
RemoveDuplicates:
enabled: true
params:
nodeResourceUtilizationThresholds: {}
RemovePodsViolatingInterPodAntiAffinity:
enabled: true
params:
nodeResourceUtilizationThresholds: {}
RemovePodsViolatingNodeAffinity:
enabled: true
params:
nodeAffinityType:
- requiredDuringSchedulingIgnoredDuringExecution
nodeResourceUtilizationThresholds: {}
RemovePodsViolatingNodeTaints:
enabled: true
params:
nodeResourceUtilizationThresholds: {}
```
It's preferred to have the following json string instead:
```
strategies:
LowNodeUtilization:
enabled: true
params:
nodeResourceUtilizationThresholds:
numberOfNodes: 1
targetThresholds:
cpu: 50
memory: 50
pods: 20
thresholds:
cpu: 50
memory: 50
pods: 20
RemoveDuplicates:
enabled: true
RemovePodsViolatingInterPodAntiAffinity:
enabled: true
RemovePodsViolatingNodeAffinity:
enabled: true
params:
nodeAffinityType:
- requiredDuringSchedulingIgnoredDuringExecution
RemovePodsViolatingNodeTaints:
enabled: true
```
2020-04-28 15:20:30 +02:00
Jan Chaloupka
077b7f6505
Drop check for MaxNoOfPodsToEvictPerNode and invoke EvictPod wrapper instead
2020-04-22 10:33:22 +02:00
Jan Chaloupka
414554ae5e
lownodeutilization: make unit tests with/without priority table driven
2020-04-17 11:32:28 +02: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
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
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
Mike Dame
4b9e732c18
Switch from glog to klog
2019-10-28 20:44:02 -04:00
Mike Dame
5b1d551ffd
update e2e test
2019-10-21 13:33:38 -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
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
Bowen Song
7245a31f52
Change hard coded leastLoadedNode=[3rd node] to searching for leastLoadedNode worker node
...
Accomodate dee89a6cc1
And format files according to gofmt verification
update version to 1.11.1
2019-07-11 17:26:06 -04:00
ravisantoshgudimetla
66a2a87e49
Start use kind for e2e tests
2019-07-11 10:03:06 -04: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
164d2b0729
Minor typo corrected
2019-05-25 11:40:03 +02:00
Sebastiaan Tammer
023a2f2a47
Replaced UID with Namespace for duplicate check, added tests (+ cleanup)
2019-05-25 11:18:11 +02:00
ravisantoshgudimetla
d0305dac3f
Low node utilization to respect priority while evicting pods
2018-08-21 14:14:26 -04:00
Jan Chaloupka
e41ef8cca3
Allow to override repository organization
...
Given the repository is build and about-to-be tested under openshift organization
we need to change the kubernetes-incubator into openshift. Yet, keeping both repos still in sync.
2018-03-29 16:34:02 +02:00
ravisantoshgudimetla
f1f8b2eaa7
Limit maximum number of pods to be evicted per node
2018-03-22 12:40:19 +01:00
ravisantoshgudimetla
de76f9b14c
E2E using gce first pass
2018-03-19 11:34:17 -04:00
Avesh Agarwal
44752e5e83
Update code and hack dir for kube 1.9 rebase.
2018-01-09 12:41:01 -05:00