Commit Graph

65 Commits

Author SHA1 Message Date
Clayton Coleman
b38c25ebf4 Shorten scheduler/factory test by making backoff a struct var 2015-01-09 13:16:30 -05:00
Daniel Smith
963000715a Merge pull request #3294 from erictune/public_storetoers
Move Listers to pkg/client/cache.
2015-01-07 15:56:14 -08:00
Eric Tune
ed74197fde Move Listers to pkg/client/cache.
I would like to use these in kubelet and kube-proxy.
This is the minimal change to get them moved.
I will follow up with changes to make interfaces consistent
and add Listers for other resources.
2015-01-07 15:33:17 -08:00
Clayton Coleman
b03fbf90f8 Make RESTClient more generic to API version, simplify version handling
RESTClient is an abstraction on top of arbitrary HTTP endpoints that
follow the Kubernetes API conventions. Refactored RESTClientFor so that
assumptions that are Kube specific happen outside of that method (so
others can reuse the RESTClient). Added more validation to client.New
to ensure clients give good input. Exposed APIVersion on RESTClient
as a method so that wrapper code (code that adds typed / structured
methods over rest endpoints like client.Client) can more easily make
decisions about what APIVersion it is running under.
2015-01-07 18:03:34 -05:00
Eric Tune
7d5ac856c5 Make Reflector helpers reusable.
Scheduler uses Reflector from pkg/client/cache.
It defines some helper classes.
I'd like to use those helpers with pkg/client/cache
in kube-proxy and kubelet too.
2015-01-07 13:49:37 -08:00
Daniel Smith
9c2cd55528 Merge pull request #3181 from smarterclayton/cleanup_http_items
Minor cleanups to request - fix initialism on HTTPClientFunc
2014-12-30 17:34:00 -08:00
Clayton Coleman
502204ad6d Do not set empty field or label selectors on requests
Default behavior for "" is already "everything"
2014-12-30 19:33:40 -05:00
Clayton Coleman
e355f54eda Update references from Path() to the appropriate segment use 2014-12-29 15:38:52 -05:00
Clayton Coleman
c9501128b6 Scheduler is printing the wrong value when no default algorithms available 2014-12-24 00:01:54 -05:00
derekwaynecarr
abb6632d75 Do not use namespace in url paths pre v1beta3 from client 2014-12-19 16:32:42 -05:00
Daniel Smith
3ade280f89 Merge pull request #2813 from derekwaynecarr/ns_url
Move namespace from query param to path part
2014-12-18 13:31:45 -08:00
Mike Danese
4850bdbe63 refactor scheduler factory to use plugin architecture style like credentialprovider and cloudprovider for configuring priority functions and fit predicates 2014-12-17 14:55:28 -08:00
derekwaynecarr
7cf664439f Move namespace from query param to path part 2014-12-16 15:55:47 -05:00
Clayton Coleman
19379b5a38 Internal rename api.Minion -> api.Node 2014-12-10 12:08:18 -05:00
Abhishek Gupta
d17cebcd2a Implementing PR feedback and adding test cases 2014-12-08 14:47:05 -08:00
Abhishek Gupta
5fa1dbc07b Implementing PR feedback
- Making ConfigFactory struct public
 - Added comments for predicate/priority functions and new methods
2014-12-08 14:47:05 -08:00
Abhishek Gupta
13831856c9 Combining scheduler priority functions using weighted averages 2014-12-08 14:47:05 -08:00
Abhishek Gupta
7f374030c1 Fixing gofmt errors 2014-12-08 14:47:05 -08:00
Abhishek Gupta
1eb28b0aa3 Scheduler changes to allow multiple priority functions 2014-12-08 14:47:05 -08:00
Abhishek Gupta
6b712cc700 Scheduler changes for extensibility 2014-12-08 14:47:05 -08:00
Eric Tune
3aa35e1941 Fix typo. 2014-11-21 09:02:14 -08:00
markturansky
8af4ccb111 v1beta3 Pod refactor 2014-11-18 09:25:42 -05:00
Paul Morie
e2be1564a4 Rename client/cache Store.Contains to ContainedIDs 2014-11-11 11:48:15 -05:00
deads2k
48b26e2dfc fix pod scheduling retry logic 2014-11-04 08:04:48 -05:00
Deyuan Deng
acf9d23b32 Stop httptest server. 2014-10-30 21:37:08 -04:00
Brendan Burns
83715dd7be Turn on node constraint scheduling. 2014-10-27 12:18:27 -07:00
Clayton Coleman
644eb70085 Refactor tests to split ObjectMeta from TypeMeta 2014-10-24 11:22:21 -04:00
Clayton Coleman
bb77a5d15f Rename ID -> Name 2014-10-22 15:00:26 -04:00
derekwaynecarr
085ca40291 Enforce unique constraint at namespace boundary in etcd, make client and server namespace aware 2014-10-16 13:02:52 -04:00
Eric Tune
6f577aa321 Merge pull request #1789 from lavalamp/eventing4
Add event creation library and implement in scheduler.
2014-10-15 15:55:26 -07:00
Daniel Smith
d4c750a878 Fix vet-go.sh and some things it complained about 2014-10-15 11:56:19 -07:00
Brendan Burns
47c4b8fc98 Add a predicate for persistent disk scheduling. 2014-10-13 15:38:25 -07:00
Brendan Burns
ddfda0521a Merge pull request #1763 from lavalamp/scheduler
Use cache for minion lookups, don't hammer apiserver
2014-10-13 15:33:29 -07:00
Daniel Smith
d34914517f Shorten 'CodecForVersionOrDie' name, add 'ResourceVersioner' to testapi 2014-10-13 14:58:06 -07:00
Daniel Smith
0431f2430d Use cache for minion lookups, don't hammer apiserver 2014-10-13 14:46:31 -07:00
Dawn Chen
135d187942 Merge pull request #1736 from brendandburns/scheduler
Switch away from the static node info
2014-10-10 15:01:09 -07:00
Brendan Burns
e6fa568ad4 Switch away from the static node info 2014-10-10 14:08:09 -07:00
Brendan Burns
b5ec8a747b Switch on the resource requested prioritization. 2014-10-09 11:29:45 -07:00
Brendan Burns
4230a8ca61 Add a least-requested priority function 2014-10-08 15:31:38 -07:00
Clayton Coleman
82bcdd3b3b Make ResourceVersion a string internally instead of uint64
Allows us to define different watch versioning regimes in the future
as well as to encode information with the resource version.

This changes /watch/resources?resourceVersion=3 to start the watch at
4 instead of 3, which means clients can read a resource version and
then send it back to the server. Clients should no longer do math on
resource versions.
2014-10-07 19:00:26 -04:00
Daniel Smith
cf203f1304 Fix build error in integration test 2014-10-07 13:10:58 -07:00
Brendan Burns
fcdefb5d30 Merge pull request #1613 from ghodss/fix_infinite_scheduler_crash
Prevent scheduler from crashing infinitely if apiserver is unreachable
2014-10-07 12:46:42 -07:00
Clayton Coleman
d3e51a0f24 Rename JSONBase -> TypeMeta in preparation for v1beta3
Will make subsequent refactor much easier
2014-10-07 11:12:16 -04:00
Sam Ghods
16641757ef Prevent scheduler from crashing infinitely if apiserver is unreachable 2014-10-06 19:28:23 -07:00
bgrant0607
fea58c9b88 Merge pull request #1561 from brendandburns/sleep
Add some backoff to the scheduler to prevent tight-looping.
2014-10-03 15:29:12 -07:00
Brendan Burns
1551b48347 Add a resource fit scheduler predicate. Set sensible defaults. 2014-10-03 15:09:59 -07:00
Brendan Burns
53304bd024 Add a backoff policy for failing pods. 2014-10-03 10:03:55 -07:00
Clayton Coleman
ff2eca97d9 Refactor the client (again) to better support auth
* Allows consumers to provide their own transports for common cases.
* Supports KUBE_API_VERSION on test cases for controlling which
  api version they test against
* Provides a common flag registration method for CLIs that need
  to connect to an API server (to avoid duplicating flags)
* Ensures errors are properly returned by the server
* Add a Context field to client.Config
2014-10-01 15:23:37 -04:00
derekwaynecarr
02e1a2e79d Update unit tests to pass a context on client create 2014-09-30 14:27:56 -04:00
Tim Hockin
a7a46f71aa Merge pull request #1449 from brendandburns/scheduler
Refactor scheduler, use generic scheduler everywhere, delete old code.
2014-09-26 12:18:52 -07:00