1
0
mirror of https://github.com/kubernetes-sigs/descheduler.git synced 2026-01-26 13:29:11 +01:00
Commit Graph

53 Commits

Author SHA1 Message Date
Jan Chaloupka
2f90d1dd01 refactor(node_taint_test): apply pod single creation convention for p9 2025-12-15 16:43:32 +01:00
Jan Chaloupka
f0cda32b6e refactor(node_taint_test): apply pod single creation convention for p8 2025-12-15 16:43:01 +01:00
Jan Chaloupka
43523113ff refactor(node_taint_test): apply pod single creation convention for p7 2025-12-15 16:42:34 +01:00
Jan Chaloupka
1b7889f4a3 refactor(node_taint_test): apply pod single creation convention for p6 2025-12-15 16:42:00 +01:00
Jan Chaloupka
b86315f097 refactor(node_taint_test): apply pod single creation convention for p5 2025-12-15 16:41:39 +01:00
Jan Chaloupka
0d496dfc5d refactor(node_taint_test): apply pod single creation convention for p4 2025-12-15 16:41:19 +01:00
Jan Chaloupka
d6b35eaed6 refactor(node_taint_test): apply pod single creation convention for p3 2025-12-15 16:40:41 +01:00
Jan Chaloupka
dc18f9f330 refactor(node_taint_test): apply pod single creation convention for p2 2025-12-15 16:39:54 +01:00
Jan Chaloupka
39212419e6 refactor(node_taint_test): apply pod single creation convention for p1 2025-12-15 16:38:35 +01:00
Jan Chaloupka
64f77ce6ee refactor(node_taint_test): apply node single creation convention for node7 2025-12-15 16:35:38 +01:00
Jan Chaloupka
ca5326c5c4 refactor(node_taint_test): apply node single creation convention for node6 2025-12-15 16:35:12 +01:00
Jan Chaloupka
9cf075ffc4 refactor(node_taint_test): apply node single creation convention for node5 2025-12-15 16:34:47 +01:00
Jan Chaloupka
3325fe0b8b refactor(node_taint_test): apply node single creation convention for node2 2025-12-15 16:33:28 +01:00
Jan Chaloupka
6c41ebd8f3 refactor(node_taint_test): apply node single creation convention for node1 2025-12-15 16:33:12 +01:00
Jan Chaloupka
ba034d6e0e refactor(node_taint_test): add node name constants 2025-12-15 16:23:38 +01:00
Jan Chaloupka
3289554f90 refactor(node_taint_test): add buildTestPod helper function 2025-12-15 16:20:01 +01:00
Jan Chaloupka
72575c2f23 refactor(node_taint_test): add buildTestNode helper function 2025-12-15 16:17:49 +01:00
Amir Alavi
1db6b615d1 [v0.34.0] bump to kubernetes 1.34 deps
Signed-off-by: Amir Alavi <amiralavi7@gmail.com>
2025-10-21 09:14:13 -04:00
googs1025
2cce141feb Improves the validation logic in the plugins
Signed-off-by: googs1025 <googs1025@gmail.com>
2025-08-07 17:21:01 +08:00
googs1025
33894afe2b feature: use contextal logging for plugins
Signed-off-by: googs1025 <googs1025@gmail.com>
2025-06-13 19:45:55 +08:00
Jan Chaloupka
1974c12e0f Extend plugin's New with a context.Context
The new context.Context can be later used for passing a contextualized
logger. Or, other initialization steps that require the context.
2025-05-19 12:23:44 +02:00
Jan Chaloupka
6691720da5 RemovePodsViolatingNodeTaints: list only pods that are not failed/suceeded
Listing pods was incorrectly changed to listing all pods during code
refactoring.
2025-05-10 21:12:06 +02:00
Amir Alavi
48aede9fde update license to year 2025
Signed-off-by: Amir Alavi <amiralavi7@gmail.com>
2025-01-02 13:36:59 -05:00
Kubernetes Prow Robot
0f1890e5cd Merge pull request #1480 from ingvagabund/omitempty-for-plugin-args
Plugin args: tag arguments with omitempty to reduce the marshalled json size
2024-09-02 12:00:56 +01:00
Jan Chaloupka
cbade38d23 [tests] de-duplicate framework handle initialization 2024-08-12 17:05:30 +02:00
Jan Chaloupka
cb0c1b660d Plugin args: tag arguments with omitempty to reduce the marshalled json size 2024-08-06 15:20:18 +02:00
zhifei92
e60f525ec6 feat: support MaxNoOfPodsToEvictTotal 2024-07-09 14:00:27 +08:00
Jan Chaloupka
18d0e4a540 PodEvictor: turn an exceeded limit into an error
When checking for node limit getting exceeded the pod eviction
never fails. Thus, ignoring the metric reporting when a pod fails
to be evicted due to node limit constrains.

The error also allows plugin to react on other limits getting
exceeded. E.g. the limit on the number of pods evicted per namespace.
2024-07-06 20:14:43 +02:00
Amir Alavi
e26f6429a2 feat: pod evictor options 2024-07-05 21:40:55 -04:00
Kubernetes Prow Robot
972d28108a Merge pull request #1447 from ingvagabund/refactorings
PodEvictor: refactoring and preparation for eviction requests
2024-06-25 01:08:44 -07:00
Jan Chaloupka
0901cb18bf NewPodEvictor: drop nodes parameter 2024-06-22 15:08:00 +02:00
zhifei92
ae15fed7e7 fix(unit-test): add necessary ownerRef to the pod. 2024-06-21 19:12:40 +08:00
etoster
b7697869f2 add argument to remove only pods violating specific node taints 2024-03-25 15:21:21 +01:00
Gabriel Tiossi
52d226321b fix(plugins): node taint wrong option 2024-03-03 03:28:18 +00:00
Gabriel Tiossi
bb5930eb21 Improve PodEvictor observability through EvictOptions (#1349)
* feat: profile name for pods_evicted metric

Support new label "profile" for "pods_evicted" metric to allow
understand which profiles are evicting more pods, allowing better
observability

* refactor: evictoptions improved observability

Send profile and strategy names for EvictOptions, allowing Evictors to
access observability information

* cleanup: remove unnecessary evictoption reference

* feat: evictoptions for nodeutilzation

Explicit usage of options when invoking evictPods from the helper
function from nodeutilization for both highnodeutilization and
lownodeutilization
2024-03-02 12:06:05 -08:00
dongjiang1989
1715f4ff81 update verify gen
Signed-off-by: dongjiang1989 <dongjiang1989@126.com>
2024-01-02 16:11:36 +08:00
Amir Alavi
359b38a34c update deprecated sets.String to generic sets 2023-05-11 22:35:44 -04:00
Jan Chaloupka
757661110a Move framework types under framework/types 2023-03-23 19:00:55 +01:00
lucming
02b1e8b8b9 remove some logic useless 2023-02-16 17:25:00 +08:00
Lucas Severo Alves
137f3b20dc add v1alpha2 registry based conversion (#1006)
* add v1alpha2 registry based conversion

* test defaults, set our 1st explicit default

* fix typos and dates

* move pluginregistry to its own dir

* remove unused v1alpha2.Namespace type

* move migration code folders, remove switch

* validate internalPolicy a single time

* remove structured logs

* simplify return

* check for nil methods

* properly check before adding default evictor

* add TODO comment

* bump copyright year
2023-01-17 08:10:34 -08:00
Amir Alavi
923921a1aa update license year by running make gen
Signed-off-by: Amir Alavi <amiralavi7@gmail.com>
2023-01-04 13:09:50 -05:00
Lucas Severo Alves
da8b145980 use plugin registry and prepare for conversion (#1003)
* use plugin registry and prepare for conersion

* Register plugins explicitly to a registry

* check interface impl instead of struc var

* setup plugins at top level

* treat plugin type combinations

* pass registry as arg of V1alpha1ToInternal

* move registry yet another level up

* check interface type separately
2022-12-01 06:05:54 -08:00
Furkan
99868a41de run: gofumpt -w -extra .
Enable gofumpt in golangci

Signed-off-by: Furkan <furkan.turkal@trendyol.com>
2022-11-07 09:11:27 +03:00
Kubernetes Prow Robot
9e2c323aa9 Merge pull request #954 from spike-liu/master
Plugin arguments defaulting + moving plugin arguments to each corresponding plugin #925
2022-09-27 03:21:51 -07:00
vlc刘诚
ac0261fafb fix pull-descheduler-verify-master build error 2022-09-24 09:29:42 +08:00
vlc刘诚
0d8106a32d RemovePodsViolatingNodeTaintsArgs defaulting 2022-09-23 11:32:38 +08:00
vlc刘诚
5a755e73f2 RemovePodsViolatingNodeTaints defaulting + moving arguments to its corresponding plugin 2022-09-23 11:32:38 +08:00
sunxiaofei
c10e6d6c12 fix sharedInformerFactory register 2022-09-22 16:02:13 +08:00
Lucas Severo Alves
edec8fe010 add PreEvictionFilter extension to DefaultEvictor Plugin 2022-09-20 17:29:41 +02:00
Lucas Severo Alves
f47c2c4407 add new preevectionfilter plugin with args 2022-09-12 16:56:21 +02:00