Commit Graph

25 Commits

Author SHA1 Message Date
Wojciech Tyczynski
cab7db3a64 Use []*api.Node instead of NodeLister in priority functions. 2016-07-21 08:21:07 +02:00
mksalawa
fea8d0aebf Fix generic scheduler test 2016-07-20 14:47:44 +02:00
Wojciech Tyczynski
d14fe0f269 Change storeToNodeConditionLister to return []*api.Node instead of api.NodeList for performance 2016-07-11 21:02:33 +02:00
Wojciech Tyczynski
6890868823 Add meta field to predicates signature 2016-07-08 12:25:48 +02:00
David McMahon
ef0c9f0c5b Remove "All rights reserved" from all the headers. 2016-06-29 17:47:36 -07:00
Hongchao Deng
e2704c9168 scheduler: remove unused random generator 2016-05-24 20:12:21 -07:00
Wojciech Tyczynski
a51f266ebf Remove nodeName from predicate signature. 2016-05-06 11:23:37 +02:00
HaiyangDING
a5efb009c5 change predicate error format. 2016-04-17 08:48:03 +08:00
Wojciech Tyczynski
545bf184ef Simplify FailedPredicateMap 2016-04-14 10:58:35 +02:00
HaiyangDING
41ed85479a move predicates into library (address #12744)
DONE:
1. refactor all predicates: predicates return fitOrNot(bool) and error(Error) in which the latter is of type
	PredicateFailureError or InsufficientResourceError. (For violation of either MaxEBSVolumeCount or
        MaxGCEPDVolumeCount, returns one same error type as ErrMaxVolumeCountExceeded)
2. GeneralPredicates() is a predicate function, which includes serveral other predicate functions (PodFitsResource,
        PodFitsHost, PodFitsHostPort). It is registered as one of the predicates in DefaultAlgorithmProvider, and
        is also called in canAdmitPod() in Kubelet and should be called by other components (like rescheduler, etc)
        if necessary. See discussion in issue #12744
3. remove podNumber check from GeneralPredicates
4. HostName is now verified in Kubelet's canAdminPod(). add TestHostNameConflicts in kubelet_test.go
5. add getNodeAnyWay() method in Kubelet to get node information in standaloneMode

TODO:
1. determine which predicates should be included in GeneralPredicates()
2. separate GeneralPredicates() into:
	a. GeneralPredicatesEvictPod() and
	b. GeneralPredicatesNotEvictPod()
3. DaemonSet should use GeneralPredicates()
2016-04-11 00:57:03 +08:00
Hongchao Deng
ae88f08af0 Scheduler: replace system modeler with scheduler cache 2016-03-14 09:03:41 -07:00
Marek Grabowski
eb2f5153b3 Revert "Scheduler: replace system modeler with scheduler cache and do O(1) lookup for resource req" 2016-03-02 15:38:56 +01:00
Hongchao Deng
f29a1d6c5c scheduler: Scheduler: replace system modeler with scheduler cache
We're using the scheduler cache to do O(1) lookup for resource request
2016-02-26 09:22:29 -08:00
Hongchao Deng
9236e4a0b4 scheduler: change fit predicates and priority func as needed for optimization 2016-02-09 09:38:28 -08:00
Oleg Shaldybin
3a36dfb306 Minor selectHost optimization in scheduler
Instead of sorting hosts by score, find max score and choose one of
the hosts with max score directly. Saves a little time on sorting and
avoids extra copying of HostPriorityList entries.

Test had to be updated as one of the test cases relied on having a
stable order from pre-sorting.
2016-02-08 12:37:37 -05:00
mqliang
e58eae313e move filter logic to list&watch client 2015-12-22 19:32:18 +08:00
Brendan Burns
0ee0e16bcd Don't recreate the same map 3 times 2015-12-16 20:39:28 -08:00
Ravi Gadde
cadc24e9fd Scheduler extension 2015-11-25 08:19:27 -08:00
Wojciech Tyczynski
53ae56f205 Replace "minion" with "node" in bunch of places. 2015-09-14 11:07:11 +02:00
tummychow
78ce5da988 Move util.StringSet into its own package
A lot of packages use StringSet, but they don't use anything else from
the util package. Moving StringSet into another package will shrink
their dependency trees significantly.
2015-09-10 12:04:15 -07:00
Jerzy Szczepkowski
d6dab28b96 Revert "Move prioritizer function EqualPriority to package priorities" 2015-08-07 15:51:26 +02:00
dinghaiyang
ebbcd4a3ba Move prioritizer function EqualPriority to package priorities 2015-08-07 09:56:54 +08:00
Mike Danese
8e33cbfa28 rewrite go imports 2015-08-05 17:30:03 -07:00
Brendan Burns
97634c7fbf Fix the scheduler to ignore terminated pods. 2015-06-10 14:38:08 -07:00
hurf
6203ce9f85 Move pkg/scheduler to plugin/pkg/scheduler
As the TODO in plugin/pkg/scheduler/scheduler.go described:

move everything from pkg/scheduler into this package. Remove
references from registry.
2015-05-13 14:03:25 +08:00