Commit Graph

169 Commits

Author SHA1 Message Date
deads2k
5a8f075197 move authoritative client-go utils out of pkg 2017-01-24 08:59:18 -05:00
Clayton Coleman
469df12038
refactor: move ListOptions references to metav1 2017-01-23 17:52:46 -05:00
deads2k
1ce0637b27 move listers out of cache to reduce import tree 2017-01-20 15:01:38 -05:00
deads2k
11e8068d3f move pkg/fields to apimachinery 2017-01-19 09:50:16 -05:00
deads2k
c47717134b move utils used in restclient to client-go 2017-01-19 07:55:14 -05:00
NickrenREN
0b94834b17 fix nodeStatusUpdateRetry count exceeding condition judgement
When tryUpdateNodeStatus() return err,err!=nil,  but nc.kubeClient.Core().Nodes().Get() return no err, err==nil,
And we run nodeStatusUpdateRetry times, when for loop ends, err == nil, we can not print error info and run continue, so the condition judgement is wrong.
2017-01-12 22:00:30 +08:00
deads2k
6a4d5cd7cc start the apimachinery repo 2017-01-11 09:09:48 -05:00
NickrenREN
639572ac68 fix redundant alias and remove unused function 2017-01-09 17:13:09 +08:00
Kubernetes Submit Queue
744876d13f Merge pull request #38798 from NickrenREN/nodecontroller-status
Automatic merge from submit-queue

delete continue in monitorNodeStatus
2016-12-21 10:35:25 -08:00
Wojciech Tyczynski
1b2d9eb2e7 NodeController listing nodes from cache instead of cache in apiserver 2016-12-20 13:13:14 +01:00
NickrenREN
fab228a4ef delete continue in monitorNodeStatus
the continue will run at the end of the for loop, we do not need it
2016-12-15 13:41:24 +08:00
Chao Xu
03d8820edc rename /release_1_5 to /clientset 2016-12-14 12:39:48 -08:00
Dan Winship
f369372dad Drop version-parsing from pkg/version
pkg/version is now just version constants, etc, not version parsing
2016-12-13 08:53:19 -05:00
Wojciech Tyczynski
e8d1cba875 GetOptions in client calls 2016-12-09 09:42:01 +01:00
Clayton Coleman
3454a8d52c
refactor: update bazel, codec, and gofmt 2016-12-03 19:10:53 -05:00
Clayton Coleman
5df8cc39c9
refactor: generated 2016-12-03 19:10:46 -05:00
Chao Xu
b50367cbdc remove v1.Semantics 2016-11-23 15:53:09 -08:00
Chao Xu
7eeb71f698 cmd/kube-controller-manager 2016-11-23 15:53:09 -08:00
Kubernetes Submit Queue
49e7d640d9 Merge pull request #35235 from foxish/node-controller-no-force-deletion
Automatic merge from submit-queue

Node controller to not force delete pods

Fixes https://github.com/kubernetes/kubernetes/issues/35145

- [x] e2e tests to test Petset, RC, Job.
- [x] Remove and cover other locations where we force-delete pods within the NodeController.

**Release note**:

<!--  Steps to write your release note:
1. Use the release-note-* labels to set the release note state (if you have access) 
2. Enter your extended release note in the below block; leaving it blank means using the PR title as the release note. If no release note is required, just write `NONE`. 
-->

``` release-note
Node controller no longer force-deletes pods from the api-server.

* For StatefulSet (previously PetSet), this change means creation of replacement pods is blocked until old pods are definitely not running (indicated either by the kubelet returning from partitioned state, or deletion of the Node object, or deletion of the instance in the cloud provider, or force deletion of the pod from the api-server). This has the desirable outcome of "fencing" to prevent "split brain" scenarios.
* For all other existing controllers except StatefulSet , this has no effect on the ability of the controller to replace pods because the controllers do not reuse pod names (they use generate-name).
* User-written controllers that reuse names of pod objects should evaluate this change.
```
2016-11-01 20:08:57 -07:00
Anirudh
5ccd7a325e Removing force deletion of pods from the node-controller 2016-11-01 11:44:34 -07:00
gmarek
8d766462e7 Initialize CIDR allocator before registering handle functions 2016-10-31 16:21:37 +01: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
Jan Chaloupka
6079053407 Update clientset generator to use RESTClient interface instead of the RESTClient data type 2016-10-21 10:13:51 +02:00
Kubernetes Submit Queue
4dbd657e67 Merge pull request #34342 from justinsb/fix_typo_initializing
Automatic merge from submit-queue

Fix typo: initilizing -> initializing
2016-10-15 09:31:53 -07:00
Andy Goldstein
e7befa2a14 Only wait for cache syncs once in NodeController 2016-10-14 15:50:05 -04:00
gmarek
e2b78ddadc NodeController waits for informer sync before doing anything 2016-10-14 15:52:57 +02:00
Kubernetes Submit Queue
06c1f2ba2c Merge pull request #34707 from gmarek/master
Automatic merge from submit-queue

Bump log level in case of Node eviction
2016-10-13 05:37:10 -07:00
gmarek
41278b4c6b Bump log level in case of Node eviction 2016-10-13 13:26:16 +02:00
gmarek
8b7e9d303c Handle DeletedFinalStateUnknown in NodeController 2016-10-13 11:31:04 +02:00
Justin Santa Barbara
dc2a9d6f5c Fix typo: initilizing -> initializing 2016-10-07 13:29:22 -04: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
Justin Santa Barbara
54195d590f Use strongly-typed types.NodeName for a node name
We had another bug where we confused the hostname with the NodeName.

To avoid this happening again, and to make the code more
self-documenting, we use types.NodeName (a typedef alias for string)
whenever we are referring to the Node.Name.

A tedious but mechanical commit therefore, to change all uses of the
node name to use types.NodeName

Also clean up some of the (many) places where the NodeName is referred
to as a hostname (not true on AWS), or an instanceID (not true on GCE),
etc.
2016-09-27 10:47:31 -04: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
gmarek
c40a36cab0 Change the eviction metric type and fix rate-limited-timed-queue 2016-09-08 12:20:51 +02:00
Kubernetes Submit Queue
9dfe8df7cd Merge pull request #32107 from xingzhou/km_bug
Automatic merge from submit-queue

Used goroutine to launch node controller's internalPodInformer.

Fixes #32103
2016-09-06 11:50:28 -07:00
Kubernetes Submit Queue
afef4b6938 Merge pull request #32070 from gmarek/nodecontroller
Automatic merge from submit-queue

Sleep between NodeStatus update retries

Just a thing I found when looking into other problems.

This is pretty much no-risk change fixing wrong behavior. Do you think it should go in 1.4? @pwittrock
2016-09-06 03:51:20 -07:00
Xing Zhou
46c302b4c2 Used goroutine to launch node controller's internalPodInformer.
Node controller's internalPodInformer will block main thread
if it is not started as a go routine. This patch fixed this
by runing internalPodInformer as a go routine.
2016-09-06 15:39:13 +08:00
Wojciech Tyczynski
b69d516763 NodeController listing nodes from apiserver cache 2016-09-05 16:52:57 +02:00
gmarek
bac603afd6 Sleep between NodeStatus update retries 2016-09-05 12:29:28 +02:00
gmarek
ea2d19f5d7 Remove unused argument to NodeController.Run 2016-08-30 14:24:56 +02:00
gmarek
5d8cb17efa Add cluster health metrics to NodeController 2016-08-18 15:11:10 +02:00
Kubernetes Submit Queue
f9190ed61a Merge pull request #30138 from gmarek/flags
Automatic merge from submit-queue

Expose flags for new NodeEviction logic in NodeController

Fix #28832
Last PR from the NodeController NodeEviction logic series. 

cc @davidopp @lavalamp @mml
2016-08-18 00:41:28 -07:00
bprashanth
15c9826061 Nodecontroller doesn't flip readiness on pods if kubeletVersion < 1.2.0 2016-08-17 15:33:35 -07:00
gmarek
4cf698ef04 Expose flags for new NodeEviction logic in NodeController 2016-08-17 10:43:24 +02:00
AdoHe
b2ab4c6d9b fix node controller event uid issue 2016-08-14 09:41:20 +08:00
Dominika Hodovska
816f6d32ca Collapse duplicate informer creation paths 2016-08-04 09:02:13 +02:00
gmarek
66224ce0bd Change eviction logic in NodeController and make it Zone-aware 2016-08-02 14:21:52 +02:00
k8s-merge-robot
59836d6dbd Merge pull request #24841 from sjenning/shared-informer
Automatic merge from submit-queue

update node controller to use shared pod informer

continuing work from #24470 and #23575
2016-08-02 03:45:01 -07:00
Matt T. Proud
76aab29ede pkg/controller/node/nodecontroller: simplify mutex
Similar to #29598, we can rely on the zero-value construction behavior
to embed `sync.Mutex` into parent structs.
2016-07-26 07:06:16 +02:00