Commit Graph

304 Commits (6c4033eea7e31016ccac83635aa7e92b1db2043f)

Author SHA1 Message Date
deads2k 5788317953 demonstrate separation of controller intializers 2016-12-05 10:24:45 -05:00
Dr. Stefan Schimanski 24e24fc7bb Add verb support to gc and namespace controllers 2016-12-05 12:36:05 +01:00
Dr. Stefan Schimanski 458d2b2fe4 Add verb support for discovery client 2016-12-05 12:36:05 +01:00
Clayton Coleman bdd880a1b4
Refactor certificate controller to make approval an interface 2016-12-01 09:55:28 -05:00
deads2k 585daa2069 use the client builder to support using SAs 2016-11-28 15:02:22 -05:00
deads2k 21c304333a return errors instead of fataling 2016-11-28 15:02:21 -05:00
deads2k 49ebc2c2ae remove unnecessary startcontroller options 2016-11-28 15:02:21 -05:00
deads2k 6080620553 simplify enabled resource checks 2016-11-28 15:02:21 -05:00
deads2k d973158a4e make controller manager use specified stop channel 2016-11-28 15:02:21 -05:00
Clayton Coleman 35a6bfbcee
generated: refactor 2016-11-23 22:30:47 -06:00
Chao Xu 7eeb71f698 cmd/kube-controller-manager 2016-11-23 15:53:09 -08:00
Brendan Burns ef6529bf2f make groupVersionResource listing dynamic when third party resources are
enabled.
2016-11-20 20:48:57 -08:00
Solly Ross 2c66d47786 HPA: Consider unready pods and missing metrics
Currently, the HPA considers unready pods the same as ready pods when
looking at their CPU and custom metric usage.  However, pods frequently
use extra CPU during initialization, so we want to consider them
separately.

This commit causes the HPA to consider unready pods as having 0 CPU
usage when scaling up, and ignores them when scaling down.  If, when
scaling up, factoring the unready pods as having 0 CPU would cause a
downscale instead, we simply choose not to scale.  Otherwise, we simply
scale up at the reduced amount caculated by factoring the pods in at
zero CPU usage.

The effect is that unready pods cause the autoscaler to be a bit more
conservative -- large increases in CPU usage can still cause scales,
even with unready pods in the mix, but will not cause the scale factors
to be as large, in anticipation of the new pods later becoming ready and
handling load.

Similarly, if there are pods for which no metrics have been retrieved,
these pods are treated as having 100% of the requested metric when
scaling down, and 0% when scaling up.  As above, this cannot change the
direction of the scale.

This commit also changes the HPA to ignore superfluous metrics -- as
long as metrics for all ready pods are present, the HPA we make scaling
decisions.  Currently, this only works for CPU.  For custom metrics, we
cannot identify which metrics go to which pods if we get superfluous
metrics, so we abort the scale.
2016-11-08 00:59:23 -05:00
Maciej Szulik 41d88d30dd Rename ScheduledJob to CronJob 2016-11-07 10:14:12 +01:00
Kubernetes Submit Queue 6ee92d9311 Merge pull request #36215 from piosz/hpa-controller
Automatic merge from submit-queue

Enable HPA controller based on autoscaling/v1 api group

ref #29778

``` release-note
Enable HPA controller based on autoscaling/v1 api group.
```
2016-11-06 07:18:15 -08:00
Kubernetes Submit Queue c02a9c6aad Merge pull request #36080 from ncdc/lister-gen
Automatic merge from submit-queue

lister-gen updates

- Remove "zz_generated." prefix from generated lister file names
- Add support for expansion interfaces
- Switch to new generated JobLister

@deads2k @liggitt @sttts @mikedanese @caesarxuchao for the lister-gen changes
@soltysh @deads2k for the informer / job controller changes
2016-11-06 06:05:23 -08:00
deads2k ebf796a649 make using service account credentials from controllers optional 2016-11-04 14:17:34 -04:00
Piotr Szczesniak 14eee1d7f0 Enable HPA controller based on autoscaling/v1 api group 2016-11-04 10:02:34 +01:00
Andy Goldstein 8c923faf74 Switch to JobLister 2016-11-03 20:41:40 -04:00
Marcin 26acced6d8 Add policy api version v1beta1 and disable v1alpha1 2016-11-03 13:26:27 +01:00
Janet Kuo c15b9470f5 Replace apps/v1alpha1 with apps/v1beta1 and manually remove generated apps/v1alpha1 files
Manually remove generated apps/v1alpha1 types, protobuf, and api-reference doc files
Manually remove apps/v1alpha1 folder from 1.5 generated client
2016-11-02 15:16:23 -07:00
derekwaynecarr 1bcb057636 quota controller uses informers if available for pod calculation 2016-10-31 11:38:22 -04:00
Chao Xu 850729bfaf include multiple versions in clientset
update client-gen to use the term "internalversion" rather than "unversioned";
leave internal one unqualified;
cleanup client-gen
2016-10-29 13:30:47 -07:00
Kubernetes Submit Queue 620788a795 Merge pull request #35230 from deads2k/controller-12-sa-controller
Automatic merge from submit-queue

convert SA controller to shared informers

convert the SA controller to shared informer + workqueue.

I think one of @derekwaynecarr @ncdc or @liggitt
2016-10-29 10:09:46 -07:00
Clayton Coleman ca2f1b87ad
Replace negotiation with a new method that can extract info
Alter how runtime.SerializeInfo is represented to simplify negotiation
and reduce the need to allocate during negotiation. Simplify the dynamic
client's logic around negotiating type. Add more tests for media type
handling where necessary.
2016-10-28 11:30:11 -04:00
Janet Kuo 10aee82ae3 Rename PetSet API to StatefulSet 2016-10-27 17:25:10 -07:00
deads2k df4ed892c4 convert SA controller to shared informers 2016-10-27 15:44:46 -04:00
Anirudh b5d9f2f336 Always run the podGC controller. 2016-10-24 17:15:39 -07:00
deads2k b471398f1f convert replica set controller to shared informer 2016-10-18 08:13:37 -04:00
deads2k aa5cbb704f convert deployment controller to shared informers 2016-10-07 15:06:57 -04:00
deads2k 8ea2acc6a3 use service accounts as clients for controllers 2016-10-05 13:15:16 -04:00
Lucas Käldström 0bba65ca1a Remove old references to contrib/mesos 2016-10-01 16:46:48 +03:00
Kubernetes Submit Queue 901e3e30b6 Merge pull request #33387 from timothysc/resource_lock_abstraction
Automatic merge from submit-queue

Abstraction of endpoints in leaderelection code

**Problem Statement**:
Currently the Leader Election code is hard coded against the endpoints api.  This causes performance issues on large scale clusters due to incessant iptables refreshes, see: https://github.com/kubernetes/kubernetes/issues/26637 

The goal of this PR is to: 

- Abstract Endpoints out of the leader election code
- Fix a known bug in the event recording 

fixes #18386

**Special notes for your reviewer**:
This is a 1st pass at abstracting the details of endpoints out into an interface.  Any suggestions around how we we want to refactor this interface is welcome and could be addressed in either this PR or follow on PR. 

/cc @ncdc @wojtek-t @rrati
2016-10-01 05:19:29 -07:00
Timothy St. Clair 4a9f72b59f Abstraction of endpoints in leaderelection code 2016-09-29 23:42:00 -05:00
deads2k 0961784a9b switch node controller to shared informers 2016-09-29 09:16:41 -04:00
gmarek cb0a13c1e5 Move orphaned Pod deletion logic to PodGC 2016-09-28 13:58:31 +02:00
Kubernetes Submit Queue b2c175c758 Merge pull request #33474 from wojtek-t/user_agent_for_master_election
Automatic merge from submit-queue

Set UserAgent in LeaderElection clients.

Ref https://github.com/kubernetes/kubernetes/issues/33259

@timothysc - FYI
2016-09-27 22:58:08 -07:00
Wojciech Tyczynski cbcce2c90f Set UserAgent in LeaderElection clients. 2016-09-27 15:22:40 +02:00
Jan Safranek a54c9e2887 Refactor volume controller parameters into a structure
persistentvolumecontroller.NewPersistentVolumeController has 11 arguments now,
put them into a structure.

Also, rename NewPersistentVolumeController to NewController, persistentvolume
is already name of the package.

Fixes #30219
2016-09-26 14:15:25 +02:00
Clayton Coleman 97c35fcc67
Allow garbage collection to work against different API prefixes
The GC needs to build clients based only on Resource or Kind. Hoist the
restmapper out of the controller and the clientpool, support a new
ClientForGroupVersionKind and ClientForGroupVersionResource, and use the
appropriate one in both places.
2016-09-22 15:00:58 -04:00
Kubernetes Submit Queue 4ab5a76338 Merge pull request #33103 from deads2k/controller-03-kill-non-generatedclient
Automatic merge from submit-queue

switch controller manager to generated clients

Switches the controller manager to generated clients.

@ncdc ptal
2016-09-22 11:37:01 -07:00
deads2k b83a317003 switch controller manager to generated clientset 2016-09-20 12:53:47 -04:00
Ilya Dmitrichenko 386fae4592
Refactor utils that deal with certs
- merge `pkg/util/{crypto,certificates}`
- add funcs from `github.com/kubernetes-incubator/bootkube/pkg/tlsutil`
- ensure naming of funcs is fairly consistent
2016-09-19 09:03:42 +01:00
Kubernetes Submit Queue 2ca15b9f76 Merge pull request #32815 from deads2k/controller-02-daemonset-informer
Automatic merge from submit-queue

convert daemonset controller to shared informers

Convert the daemonset controller completely to `SharedInformers` for its list/watch resources.

@kubernetes/rh-cluster-infra @ncdc
2016-09-16 09:39:57 -07:00
deads2k 234d68be83 convert daemonset controller to shared informers 2016-09-16 10:40:46 -04:00
Kubernetes Submit Queue e8fbcb1669 Merge pull request #32654 from soltysh/sj_clientset
Automatic merge from submit-queue

Switch ScheduledJob controller to use clientset

**What this PR does / why we need it**:
This is part of #25442. I've applied here the same fix I've applied in the manual client in #29187, see the 1st commit for that (@caesarxuchao we've talked about it in #29856).

@deads2k as promised 
@janetkuo ptal
2016-09-16 05:03:57 -07:00
Mike Danese a765d59932 move informer and controller to pkg/client/cache
Signed-off-by: Mike Danese <mikedanese@google.com>
2016-09-15 12:50:08 -07:00
Kubernetes Submit Queue 843d7cd24c Merge pull request #32576 from wongma7/revert-30825-pv-controller-informer
Automatic merge from submit-queue

Revert "Use PV shared informer in PV controller"

Fixes #32497 

Reverts kubernetes/kubernetes#30825
2016-09-15 04:37:29 -07:00
gmarek 4f0129b023 Create a flag for route reconciliatio and deprecate unused node-sync-period one 2016-09-14 11:49:50 +02:00
Maciej Szulik 7a34347f7f Move ScheduledJob controller to use generated clientset 2016-09-14 11:27:29 +02:00