SataQiu
a0efc33158
wrap errors from NodeLabel, NodePorts, NodePreferAvoidPods and NodeResourcesBalancedAllocation plugins
2020-10-10 11:00:40 +08:00
Aldo Culquicondor
c8a0b9e8e7
Add defaultingType to PodTopologySpreadArgs
...
Change-Id: Ibf6a4fdb39a31fe9deed68de7e7cb24a9bf9d06a
2020-10-09 17:12:12 -04:00
Kubernetes Prow Robot
281412b5e9
Merge pull request #95191 from alculquicondor/policy-default-spread
...
Move predicates and priorities configuration creation to Policy mapping
2020-10-05 17:04:33 -07:00
Kubernetes Prow Robot
2f15024e7d
Merge pull request #95157 from adtac/schedplugins
...
scheduler framework: document how to make plugins configurable
2020-10-05 17:04:20 -07:00
Adhityaa Chandrasekar
3e7b2c0707
scheduler framework: document how to make plugins configurable
...
Signed-off-by: Adhityaa Chandrasekar <adtac@google.com>
2020-10-05 21:29:11 +00:00
Aldo Culquicondor
a0b72dbef9
Move predicates and priorities configuration creation to Policy mapping
...
For separation of concerns. Also make the producers receive the
existing configuration so they can take decisions based on them.
Change-Id: Id5db5588aabb90e7b8f087bd3f3c967e86dc4acc
2020-10-01 15:04:24 -04:00
Kubernetes Prow Robot
5b33feb943
Merge pull request #95146 from draveness/patch-5
...
fix: use ">" instead of ">=" in resource allocation
2020-09-30 12:55:08 -07:00
Draven
79f05c65a0
fix: use ">" instead of ">=" in resource allocation
2020-09-30 11:06:17 +08:00
Kubernetes Prow Robot
8deb70c2ad
Merge pull request #95091 from arghya88/wrap-errors-plugins-selectorspread/podtopologyspread
...
wrap errors in selectorspread and podtoplogyspread plugin
2020-09-29 13:43:25 -07:00
Kubernetes Prow Robot
3a987d5b85
Merge pull request #95130 from alculquicondor/fix-snapshot
...
Fix UpdateSnapshot when Node is partially removed
2020-09-28 21:31:38 -07:00
Aldo Culquicondor
d6f09f7dfb
Fix UpdateSnapshot when Node is partially removed
...
Change-Id: I5b459e9ea67020183c87d1ce0a2380efb8cc3e05
2020-09-28 17:50:41 -04:00
Aldo Culquicondor
290bdf3f08
Fix test name TestDump
...
Change-Id: If885303b86060aed7a3e2aa20450cadd1f30752c
2020-09-28 15:30:05 -04:00
Arghya Sadhu
8154dc95b5
wrap errors in selectorspread and podtoplogyspread plugin
2020-09-28 21:28:54 +05:30
Arghya Sadhu
ad415b9f54
wrap errors in service affinity plugin
2020-09-27 11:28:31 +05:30
Arghya Sadhu
ff3c751afc
wrap errors in taint-toleration plugin
2020-09-26 21:16:41 +05:30
SataQiu
8c51c9955c
wrap errors from DefaultPreemption, ImageLocality and NodeAffinity plugins
2020-09-25 10:38:27 +08:00
Kubernetes Prow Robot
44cd4fcedc
Merge pull request #95001 from arghya88/deprecate-scheduler-metrics
...
deprecate scheduler metrics
2020-09-24 13:57:48 -07:00
Kubernetes Prow Robot
769f047675
Merge pull request #95024 from chendave/exported
...
Use the exported struct member directly
2020-09-24 09:24:34 -07:00
Kubernetes Prow Robot
48cb3b2b4f
Merge pull request #94850 from SataQiu/structed-log-20200917
...
Using structured logging in scheduler framework runtime
2020-09-24 09:24:06 -07:00
SataQiu
47c58c3785
using structured logging in scheduler framework runtime
2020-09-24 21:54:31 +08:00
Dave Chen
a9b71c198b
Use the exported struct member directly
...
Signed-off-by: Dave Chen <dave.chen@arm.com>
2020-09-24 16:15:11 +08:00
Arghya Sadhu
078b355da3
deprecate scheduler metrics BindingLatency and SchedulingAlgorithmPreemptionEvaluationDuration
2020-09-23 17:15:13 +05:30
Kubernetes Prow Robot
18782e9996
Merge pull request #94884 from arghya88/remove-deprecated-scheduler-metrics
...
removing deprecated scheduler metrics
2020-09-22 14:42:32 -07:00
Kubernetes Prow Robot
9aae0ac354
Merge pull request #94864 from alculquicondor/empty-default-constraints
...
Tests for empty constraints array when DefaultPodTopologySpread is enabled
2020-09-22 14:42:09 -07:00
Kubernetes Prow Robot
a576196076
Merge pull request #94413 from chendave/flake
...
Enhancement on the testcase to cover more possibilities
2020-09-22 12:23:20 -07:00
Arghya Sadhu
c62f0dd165
removing deprecated scheduler metrics
2020-09-22 21:04:15 +05:30
Aldo Culquicondor
e856706984
Tests for empty constraints array when DefaultPodTopologySpread is enabled
...
An empty array in the configuration signifies that the user operator intends to disable the k8s provided default for TopologyPodSpread.
Signed-off-by: Aldo Culquicondor <acondor@google.com>
Change-Id: Ib4696a49f0ba748183aef417b0882d494b89f602
2020-09-17 14:55:53 -04:00
Kubernetes Prow Robot
965137a992
Merge pull request #94692 from alculquicondor/wrap_errors_min
...
Wrap errors from VolumeBinding and DefaultBinder plugins
2020-09-15 18:27:34 -07:00
Kubernetes Prow Robot
b14fcc544b
Merge pull request #92846 from Huang-Wei/rm-pvcLister
...
Remove pvcLister from genericScheduler
2020-09-15 07:54:07 -07:00
Jimmy Zhang
1f0bcc8f5d
optimize the use of informer for scheduler
2020-09-15 18:21:40 +08:00
Wei Huang
185ba08fcd
Move podPassesBasicChecks() to VolumeBinding plugin
2020-09-11 13:54:02 -07:00
Wei Huang
42cfda2f94
Remove pvcLister from genericScheduler
...
PVCLister can be fetched from sharedInformerFactory.
2020-09-11 13:54:01 -07:00
Kubernetes Prow Robot
d39214ade1
Merge pull request #94603 from wojtek-t/migrate_leader_election_to_leases_todos
...
Migrate scheduler, controller-manager and cloud-controller-manager to use LeaseLock
2020-09-11 00:08:14 -07:00
Kubernetes Prow Robot
bd39d3933b
Merge pull request #94701 from Huang-Wei/rm-disablePreemption
...
Remove field disablePreemption from internal scheduler codebase
2020-09-10 22:14:14 -07:00
Aldo Culquicondor
7fb40fc03c
Wrap errors on VolumeBinding plugin
...
Signed-off-by: Aldo Culquicondor <acondor@google.com>
Change-Id: I23053528ac6857124fddd7f9fa26e122202ff4bd
Signed-off-by: Aldo Culquicondor <acondor@google.com>
2020-09-10 16:22:16 -04:00
Aldo Culquicondor
94985e28ac
Wrap errors on DefaultBinder plugin
...
Signed-off-by: Aldo Culquicondor <acondor@google.com>
Change-Id: I2e3c8aa2c1a2a5102e9110b6cff91d66a79a90f1
2020-09-10 16:22:16 -04:00
Aldo Culquicondor
aefcfcc627
Wrap errors when running Bind plugins
...
Signed-off-by: Aldo Culquicondor <acondor@google.com>
Change-Id: I29f8d3ea219a5cf667cf718545e8dfff971ca6ec
2020-09-10 16:22:15 -04:00
Aldo Culquicondor
a482d7ef8e
Wrap errors when running PreBind plugins
...
Signed-off-by: Aldo Culquicondor <acondor@google.com>
Change-Id: I31bf35d7e96b1cebb285cf03ffad310d83224d9c
Signed-off-by: Aldo Culquicondor <acondor@google.com>
2020-09-10 16:22:12 -04:00
Wei Huang
eb3d2de543
Remove field disablePreemption from internal scheduler codebase
2020-09-10 13:06:42 -07:00
Aldo Culquicondor
34102140e2
Hold error in framework's Status
...
To allow obtaining and comparing the original error.
Signed-off-by: Aldo Culquicondor <acondor@google.com>
Change-Id: Ibcef89f7b876a273ecc24548f8d204966e0e6059
2020-09-10 10:52:36 -04:00
wojtekt
805c1753cd
Migrate scheduler, controller-manager and cloud-controller-manager to lease lock.
2020-09-10 11:57:18 +02:00
Wei Huang
4f7ae54f3e
fixup: add podLister as a member field of DefaultPreemption
2020-09-08 18:27:23 -07:00
Wei Huang
52bf6ba8ba
Preemption plugin to fetch pod from informer cache
2020-09-08 18:27:23 -07:00
Wei Huang
d8def59871
Initialize scheduler's podInformer in sharedInformerFactory
...
Scheduler's specific podInfomer is now initialized inside the sahredInformerFactory.
2020-09-08 12:57:17 -07:00
Kubernetes Prow Robot
44ecd80cf1
Merge pull request #91557 from chendave/cleanup
...
cleanup: remove useless methods
2020-09-08 06:27:44 -07:00
Kubernetes Prow Robot
d239cdfbc0
Merge pull request #94059 from ahg-g/ahg-anti-affinity
...
Track pods with required anti-affinity
2020-09-08 04:54:12 -07:00
Kubernetes Prow Robot
6b388f0684
Merge pull request #94187 from chendave/avoid_apicall
...
Avoid the API call to update pod if nothing is changed
2020-09-07 15:01:44 -07:00
Kubernetes Prow Robot
62d46b8b8b
Merge pull request #94573 from siadat/double-pointer
...
Remove unnecessary double-pointer
2020-09-07 14:02:07 -07:00
Kubernetes Prow Robot
b837699f74
Merge pull request #94125 from soulxu/only_includes_all_nodes_for_preferred
...
Only process all nodes when incoming pod has no preferred affinity
2020-09-07 14:01:58 -07:00
Kubernetes Prow Robot
2481e88485
Merge pull request #93473 from Nordix/sched-fix-mael
...
Change nodeInfolist building logic in scheduler
2020-09-07 14:01:44 -07:00
Sina Siadat
6b18ff81a5
Remove unnecessary double-pointer
2020-09-06 16:22:06 +04:30
Kubernetes Prow Robot
217d89a59f
Merge pull request #93843 from soulxu/fast_path_podaffinity
...
Fast return when no any matched anti-affinity terms
2020-09-04 03:31:55 -07:00
Dave Chen
4b2c054e59
Enhancement on the testcase to cover more possibilities
...
This change enriches the testcase of `TestPriorityQueue_MoveAllToActiveOrBackoffQueue`
to cover the case that pods in the unschedulableQ could be moved to activeQ after the
backing off.
Signed-off-by: Dave Chen <dave.chen@arm.com>
2020-09-03 14:04:03 +08:00
Dave Chen
77056e89e4
Avoid the API call to update pod if nothing is changed
...
Signed-off-by: Dave Chen <dave.chen@arm.com>
2020-09-02 14:38:11 +08:00
Yuan Chen
f6f9bf3e76
Update comments in pkg/scheduler/framework/v1alpha1/interface.go
2020-08-31 15:51:42 -07:00
Kubernetes Prow Robot
2382628f16
Merge pull request #93246 from lixiaobing1/lxb-remove-algorithm
...
remove some notes about scheduler/algorithm
2020-08-28 06:36:18 -07:00
Kubernetes Prow Robot
72350a3cf7
Merge pull request #93083 from Huang-Wei/dupe-import-alias
...
Remove duplicate path imports
2020-08-28 04:34:53 -07:00
Kubernetes Prow Robot
27c9bd4fd4
Merge pull request #92939 from yuanchen8911/patch-1
...
Fix an error in PreBindPlugin comment
2020-08-27 19:08:04 -07:00
Kubernetes Prow Robot
a4103dfeaf
Merge pull request #92819 from chendave/cleanup_machine
...
Change the node name from "machine" to "node"
2020-08-27 19:06:57 -07:00
Kubernetes Prow Robot
9062c43b76
Merge pull request #94211 from soulxu/cleanup_candidates
...
Initialize candidate directly instead of iterating the array of candidates
2020-08-27 16:08:06 -07:00
Kubernetes Prow Robot
9bba0390ed
Merge pull request #94083 from soulxu/shrink_lock_scope
...
Only lock statuses map when status isn't successful
2020-08-27 16:07:57 -07:00
Kubernetes Prow Robot
90b8163b32
Merge pull request #93808 from zhouya0/seperate_registry_and_feature_gates
...
Scheduler ListAlgorithmProviders function return providers directly
2020-08-27 16:07:28 -07:00
Kubernetes Prow Robot
a5160414e0
Merge pull request #93706 from SimpCosm/fix/scheduler-plugin-comment
...
Fix an error in NodeUnschedulable plugin comment
2020-08-27 16:06:48 -07:00
Kubernetes Prow Robot
19064f4738
Merge pull request #93669 from Mr-Linus/patch-1
...
Remove unnecessary conversion
2020-08-27 16:06:25 -07:00
He Jie Xu
0e8bd4c550
Initialize candidate directly instead of iterating the array of candidates
...
Using existing victimsMap to get the victims, then it is easy to build candidate
directly.
2020-08-27 23:29:36 +08:00
Kubernetes Prow Robot
06eb495a0f
Merge pull request #93896 from alculquicondor/speed-up-volume-binding-test
...
Improve running time of TestSchedulerWithVolumeBinding
2020-08-26 19:41:10 -07:00
He Jie Xu
ccd8eb3b1b
Only process all nodes when incoming pod has no preferred affinity
...
Currently, in interpodaffinty plugin, it only processes all nodes when the incoming
pod with affinity. Actually, it only cares about all nodes when the incoming pod
with preferred affinity. Then it will reduces the number of nodes need to be
processed.
2020-08-25 16:13:17 +08:00
Linus Lee 李俊江
e55856048d
Remove unnecessary conversion
...
Update framework.go
Update framework.go
Update framework.go
remove unnecessary conversion
remove unnecessary conversion
remove unnecessary conversion
remove unnecessary conversion
2020-08-25 10:07:11 +08:00
Kubernetes Prow Robot
1c93be24ee
Merge pull request #93629 from cofyc/93009
...
fix flaky TestVolumeBinding unit test
2020-08-21 08:33:40 -07:00
Abdullah Gharaibeh
a8873e1a43
Track pods with required anti-affinity
...
This is a performance optimization that reduces the overhead of inter-pod affinity PreFilter calculaitons. Basically
eliminates that overhead when no pods in the cluster use required pod anti-affinity. This offered 20% improvement on 5k clusters for preferred anti-affinity benchmarks.
2020-08-21 10:09:21 -04:00
He Jie Xu
dc52b69ddc
Only lock statuses map when status isn't successful
...
Determine the status successful or not first, that will reduce the chance
of lock contention.
2020-08-18 22:40:15 +08:00
maelk
fc5edb8c12
Change nodeInfolist building logic in scheduler
...
This commit transforms the next() function of the scheduler node
tree into a listNodes() function that directly returns a list of
nodes, going through the zones in a round-robin fashion. This
removes the flawed logic of the next() function.
2020-08-18 11:35:14 +03:00
Kubernetes Prow Robot
3647766cbc
Merge pull request #93938 from alculquicondor/revert-node-delete
...
Keep track of remaining pods when a node is deleted
2020-08-13 13:25:41 -07:00
Aldo Culquicondor
dfe9e413d9
Keep track of remaining pods when a node is deleted.
...
The apiserver is expected to send pod deletion events that might arrive at a different time. However, sometimes a node could be recreated without its pods being deleted.
Partial revert of https://github.com/kubernetes/kubernetes/pull/86964
Signed-off-by: Aldo Culquicondor <acondor@google.com>
Change-Id: I51f683e5f05689b711c81ebff34e7118b5337571
2020-08-13 14:24:01 -04:00
Aldo Culquicondor
16d7ecfa45
Remove direct accesses to cache's node map
...
Signed-off-by: Aldo Culquicondor <acondor@google.com>
Change-Id: Iebb22fc816926aaa1ddd1e4b2e52f335a275ffaa
Signed-off-by: Aldo Culquicondor <acondor@google.com>
2020-08-13 14:22:06 -04:00
lixiaobing1
7920de5b57
remove some notes about scheduler/algorithm
2020-08-13 10:01:54 +08:00
zhouya0
a1c3ebdffc
Seperate registry and feature gates
2020-08-12 09:06:21 +08:00
Kubernetes Prow Robot
4750523bac
Merge pull request #93893 from alculquicondor/fix-scheduler-test
...
Sync cache before starting scheduler test
2020-08-11 15:31:46 -07:00
Aldo Culquicondor
1978866474
Improve running time of TestSchedulerWithVolumeBinding
...
Only wait for finished binding or error, but not both
Signed-off-by: Aldo Culquicondor <acondor@google.com>
Change-Id: I13d16e6c7c45c6527591aa05cc79fc5e96d47a68
2020-08-11 17:31:29 -04:00
Aldo Culquicondor
24f817a487
Sync cache before starting scheduler test
...
Signed-off-by: Aldo Culquicondor <acondor@google.com>
Change-Id: I9629e1d6d510607b505b0302e23d67e0ae4a662e
2020-08-11 13:36:54 -04:00
Yecheng Fu
1176ef9c7d
forget the pod when the reserve plugins fail
...
and move the metrics function calls before all other functions
2020-08-11 21:28:33 +08:00
He Jie Xu
75ccb90407
Fast return when no any matched anti-affinity terms
...
When check the incoming pod's anti-affinity rules, there is change to
return early when there is no any matched anti-affinity terms in the
whole cluster.
2020-08-10 14:53:10 +08:00
houmin
868dd41a96
Fix an error in NodeUnschedulable plugin comment
2020-08-10 11:20:23 +08:00
Kubernetes Prow Robot
377287ad37
Merge pull request #93660 from damemi/1.19-affinity-validation
...
Add LabelSelector validation in Pod Affinity/AntiAffinity Filter and Score plugins
2020-08-08 03:40:19 -07:00
Mike Dame
012245c5b9
Add LabelSelector validation in Pod Affinity/AntiAffinity Filter and Score plugins
...
The lack of this validation on incoming pods causes unpredictable cluster outcomes
when later calculating affinity results against existing pods (see #92714 ). This fix
quickly addresses the main source where these problems should be caught.
It is unfortunately difficult to add this validation directly to the API server due
to the fact that it may break migrations with existing pods that fail this check. This
is a compromise to address the current issue.
2020-08-07 12:17:40 -04:00
Shingo Omura
ef1fab7642
expose Run[Pre]ScorePlugins functions in PluginRunner interface
2020-08-04 22:50:13 +09:00
Yecheng Fu
96d0408a89
fix TestVolumeBinding unit test
2020-08-03 07:06:06 +08:00
Kubernetes Prow Robot
c1b772fb33
Merge pull request #93516 from soulxu/fix_node_tree_test
...
Create new slice to avoid modify original fake data
2020-08-01 22:59:39 -07:00
Wei Huang
0e71facefe
Hold Pod in cache until all other cleanup work is completed
...
- Move "ForgetPod" after "RunReservePluginsUnreserve", so that the cache would hold the pod to
avoid it's being retried simutaneously until Unreserve is completed.
- Move "assume" ahead of "RunReservePluginsReserve". This is based on the fact that "ForgetPod" is
the last step of failure path, so "assume" should be reversly treated as the first step. The
current failure path is like this:
assume -> reserve -> unreserve -> forgetPod -> recordingFailure
- Make subtests of TestReservePluginUnreserve stateless
2020-07-29 11:27:19 -07:00
He Jie Xu
33a7e94b6a
Create new slices to avoid modify original fake data
...
When create fake data for the nodeTree unittests, The 'append' is invoked
on the common fake data set. That makes the unittests is running with unexpected
fake data after that.
2020-07-29 11:36:47 +08:00
Kubernetes Prow Robot
19caf38665
Merge pull request #93425 from liggitt/string-cast
...
Fix int->string casts
2020-07-24 23:12:16 -07:00
Jordan Liggitt
124a5ddf72
Fix int->string casts
2020-07-24 16:23:12 -04:00
Kubernetes Prow Robot
5a50c5c95f
Merge pull request #93355 from Nordix/sched-fix-mael
...
Fix scheduler issue with nodetree additions
2020-07-24 12:10:22 -07:00
Maël Kimmerlin
c2ec8bedbc
Fix scheduler issue with nodetree additions
...
When nodes are added in multiple zones at once, the nodeTree next
function does not return a correct list of nodes but repeats some
This commit resets the index before starting to call next() to
prevent this issue
Special thanks to igraecao for the help in finding the bug
Co-authored-by: igraecao <matvej.yolli@outlook.com>
2020-07-24 09:42:53 +03:00
Kubernetes Prow Robot
e884b40e73
Merge pull request #93371 from ahg-g/ahg-volume
...
Optimize VolumeRestriction plugin
2020-07-23 16:10:23 -07:00
Abdullah Gharaibeh
5e81a2de98
Optimize VolumeRestrictions scheduler plugin
2020-07-22 23:00:01 -04:00
Abdullah Gharaibeh
44d9497133
Increase the size of the buckets for PodSchedulingDuration scheduler metric.
2020-07-22 16:42:01 -04:00
Kubernetes Prow Robot
275eabdf72
Merge pull request #93259 from jpbetz/revert-88936
...
Revert nested trace PR#88936
2020-07-20 19:51:47 -07:00
Joe Betz
02cf58102a
Revert nested trace PR#88936
2020-07-20 09:55:05 -07:00
Abdullah Gharaibeh
6f9794d5e9
Rename pod_preemption_metrics to preemption_metrics. Since this metric's type was changed from Gauge to Histogram, renaming it should make it easier to providers to migrate
2020-07-20 11:44:10 -04:00