Commit Graph

3356 Commits (56dc8f9a6ab09debeddf5349ee26730d3e9107f8)

Author SHA1 Message Date
hzxuzhonghu ad06747027 remove redundant deleting endpoint explicitly in endpoint controller 2018-01-02 20:35:30 +08:00
Christoph Blecker 80e344644e
Regenerate all generated code 2018-01-02 00:21:07 -08:00
hzxuzhonghu bfa462a8c0 optimize volumeResizeMap lock 2017-12-28 14:44:36 +08:00
Jeff Grafton efee0704c6 Autogenerate BUILD files 2017-12-23 13:12:11 -08:00
Cao Shufeng 5800c32fb6 [quota controller] remove extra queue.Add()
requeue immediately after an error may end-up with hot-loop
2017-12-23 17:17:35 +08:00
Jordan Liggitt df60789a7e
Requeue unobserved nodes in attemptToDelete 2017-12-21 14:00:07 -05:00
linyouchong 4acc23b409 fix incorrect comment 2017-12-21 23:36:20 +08:00
Jordan Liggitt a7c7da76d5
Ensure dependents are added to virtual node before attemptToDelete 2017-12-21 02:57:47 -05:00
Kubernetes Submit Queue 1cfbd3c45a
Merge pull request #57349 from deads2k/quota-01-tighten
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

add watch to requirements for quota-able resources

Since we use informers, if you can't be watched, you can't be quota'ed.
2017-12-20 14:52:25 -08:00
Josh Horwitz ffba27d72e Refactor service controller to common controller pattern 2017-12-19 23:08:48 -05:00
David Eads 541a9b42b1 add watch to requirements for quota-able resources 2017-12-18 14:50:09 -05:00
Walter Fender 070a7b5823 Seperate loop and plugin control
Seperate loop and plugin control in the kube-controller-manager.
Adding an "--external-plugin" flag to specify a plugin to load when
cloud-provider is set to "external". Flag has no effect currently
when the cloud-provider is not set to external. The expectation is
that the cloud provider and external plugin flags would go away once
all cloud providers are on stage 2 cloud-controller-manager solutions.

Managing the control loops more directly based on start up flags.
Addressing issue brought up by @wlan0

Switched to using the main node controller in CCM.
Changes to enable full NodeController to start in CCM.
Fix related tests.
Unifying some common code between KCM and CCM.
Fix related tests and comments.
Folded in feedback from @jhorwit2 and @wlan0
2017-12-18 10:58:45 -08:00
Kubernetes Submit Queue a73aee954f
Merge pull request #56872 from davidz627/logImprovement
Automatic merge from submit-queue (batch tested with PRs 56375, 56872, 57053, 57165, 57218). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Improved event generation in volume mount,attach, and extend operations

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Fixes #57217

refactored mount, attach, extend operation's so that all failures generate events and event generation is more consistent.

```release-note
Improved event generation in volume mount, attach, and extend operations
```
2017-12-17 05:33:41 -08:00
Kubernetes Submit Queue bf34ba3cb9
Merge pull request #56702 from soltysh/backoff_limit_reset
Automatic merge from submit-queue (batch tested with PRs 54902, 56831, 56702, 56287, 56878). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Add job controller test verifying if backoff is reseted on success

This adds a test for our job controller proving that the backoff limit is being reseted after a successful run. 

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

```release-note
NONE
```
2017-12-16 09:33:39 -08:00
Kubernetes Submit Queue 77333e95e4
Merge pull request #56831 from oracle/for/upstream/master/56830
Automatic merge from submit-queue (batch tested with PRs 54902, 56831, 56702, 56287, 56878). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Ensure PVL controller is next pending initializer before labeling the PV

**What this PR does / why we need it**:

According the [documentation](https://kubernetes.io/docs/admin/extensible-admission-controllers/#how-are-initializers-triggered), initializer controllers should only initialize the object once its name is at `metadata.initializers.pending[0]`.[Currently](https://github.com/kubernetes/kubernetes/blob/master/pkg/controller/cloud/pvlcontroller.go#L268), the PVL controller just checks if its name is in the list at all and ignores ordering. 

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #56830

**Special notes for your reviewer**:

**Release note**:

```release-note
Fix the PersistentVolumeLabel controller from initializing the PV labels when it's not the next pending initializer.
```

/kind bug
/sig storage
/area cloudprovider

/cc @wlan0 @luxas @liggitt
2017-12-16 09:33:36 -08:00
Kubernetes Submit Queue 0e8683e173
Merge pull request #56746 from xuri/patch
Automatic merge from submit-queue (batch tested with PRs 56639, 56746, 56715, 56673, 56726). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Simple code and typo fixed.

**What this PR does / why we need it**:
Simple code and typo fixed.
**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #
none
**Special notes for your reviewer**:
none
**Release note**:

```release-note
NONE
```
2017-12-16 06:39:42 -08:00
Kubernetes Submit Queue ec194b3615
Merge pull request #55236 from antoniaklja/50598
Automatic merge from submit-queue (batch tested with PRs 56579, 55236, 56512, 56549, 56538). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

#50598: Added more test cases for nodeShouldRunDaemonPod

**What this PR does / why we need it**:
Covered more predicates for `nodeShouldRunDaemonPod` test

**Which issue(s) this PR fixes**:
Fixes #50598

**Special notes for your reviewer**:
I've introduced `predicateName` parameter in order to easier determine what is covered. 
Currently we have:
- ShouldRunDaemonPod
- InsufficientResourceError
- ErrPodNotMatchHostName
- ErrPodNotFitsHostPorts
- ErrNodeSelectorNotMatch

TODO:
- ErrDiskConflict
- ErrPodAffinityNotMatch
- ErrTaintsTolerationsNotMatch

for more predicates take a look at [predicates/errors.go](58fd063a6c/plugin/pkg/scheduler/algorithm/predicates/error.go (L25))
2017-12-15 21:19:37 -08:00
Kubernetes Submit Queue 3abbd6fb1f
Merge pull request #56298 from pospispa/566-improvements-suggested-by-thockin-during-review-of-PR55824
Automatic merge from submit-queue (batch tested with PRs 56401, 56506, 56551, 56298, 56581). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Addressing Comments from Code Review

**What this PR does / why we need it**: addressing comments from code review: https://github.com/kubernetes/kubernetes/pull/55824#pullrequestreview-78597250

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*: N/A


**Special notes for your reviewer**:
@thockin @jsafrane @msau42 PTAL

**Release note**:

```release-note
NONE
```
2017-12-15 20:29:36 -08:00
Kubernetes Submit Queue f588bb02f3
Merge pull request #56150 from php-coder/fix_format_string
Automatic merge from submit-queue (batch tested with PRs 57211, 56150, 56368, 56271, 55957). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

pkg/controller/garbagecollector/garbagecollector.go: fix string format

**What this PR does / why we need it**:
This PR fixes broken formatting in the warning message by using appropriate function:
> W1121 13:13:39.359283   19160 garbagecollector.go:601] failed to discover preferred resources: %vGet https://127.0.0.1:37983/api: dial tcp 127.0.0.1:37983: getsockopt: connection refused

**Special notes for your reviewer**:
This change was introduced in #55259

**Release note**:
```release-note
NONE
```

PTAL @ironcladlou 
CC @simo5
2017-12-15 14:00:41 -08:00
Kubernetes Submit Queue a0d2337383
Merge pull request #57211 from liggitt/gc-cluster-scoped
Automatic merge from submit-queue (batch tested with PRs 57211, 56150, 56368, 56271, 55957). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Process cluster-scoped owners correctly

Rework of https://github.com/kubernetes/kubernetes/pull/54943
Fixes #54940

Uses correct scope info from the restmapper at point of object lookup.

```release-note
Fixed a garbage collection race condition where objects with ownerRefs pointing to cluster-scoped objects could be deleted incorrectly.
```
2017-12-15 14:00:38 -08:00
Kubernetes Submit Queue 0213f10eed
Merge pull request #55685 from gyliu513/nc-log
Automatic merge from submit-queue (batch tested with PRs 56161, 56324, 55685, 56409, 55296). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

NC should log the whole node condition.

**What this PR does / why we need it**:

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Fixes #

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```

/cc @gmarek
2017-12-15 04:33:43 -08:00
Kubernetes Submit Queue 34e73a77ac
Merge pull request #56161 from ericchiang/go-jose-import
Automatic merge from submit-queue (batch tested with PRs 56161, 56324, 55685, 56409, 55296). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

bootstrap: use gopkg.in import for square/go-jose

xref #55514

For 1.10. Ignore while 1.9 code freeze is in effect.

```release-note
NONE
```
2017-12-15 04:33:38 -08:00
Jordan Liggitt 34c3a254d8
Process cluster-scoped owners correctly 2017-12-14 22:53:59 -05:00
Kubernetes Submit Queue e87d8511b1
Merge pull request #49608 from guangxuli/fix_nodestatus_update_prints
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

The printing level for node updated failed info should be used WARNING type

**What this PR does / why we need it**:

when I add the new node to the currnent kubernetes cluster, the kube-controller-manager always outputs the error msg( `Failed to set statusUpdateNeeded to needed true because nodeName="openpass-215"  does not exist)` and (`Failed to update statusUpdateNeeded field in actual state of world: Failed to set statusUpdateNeeded to needed true because nodeName="openpass-215"  does not exist`). 

The results of invocation `updateNodeStatusUpdateNeeded` have two context, normal and abnormal.
The normal context is adding a new node to the cluster, the abnormal context is really exist some errors.

The printing level is confusing because it awlays outputs the error level msg.

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

none

/cc @saad-ali
2017-12-14 14:58:11 -08:00
David Zhu e3f8f64c17 refactored mount, attach, resize operation's so that all failures generate events and event generation is more consistent.
refactored operation generator and operation executor to use more general generated functions for operations, completions, and events.
2017-12-14 11:09:12 -08:00
Eric Chiang 8dc4c4089b pkg/controller/bootstrap: update jose package 2017-12-14 09:37:55 -08:00
Kubernetes Submit Queue baf93c060e
Merge pull request #55995 from supereagle/extensions-client-with-version
Automatic merge from submit-queue (batch tested with PRs 55900, 55995, 55913, 55467, 55376). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Use extensions client with explicit version

**What this PR does / why we need it**:
Extensions client without explicit version has been deprecated, change them to the one with explicit version.

**Which issue(s) this PR fixes**:
Fixes partially #55993

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-12-14 00:45:15 -08:00
Kubernetes Submit Queue 876259435a
Merge pull request #55991 from supereagle/core-client-with-version
Automatic merge from submit-queue (batch tested with PRs 54604, 55781, 55806, 55935, 55991). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Use core client with explicit version

**What this PR does / why we need it**:
Core client without explicit version has been deprecated, change them to the one with explicit version.

**Which issue(s) this PR fixes**:
Fixes partially #55993

**Special notes for your reviewer**:
/cc @kubernetes/sig-api-machinery-pr-reviews
/cc @caesarxuchao @k82cn @sttts @kevin-wangzefeng 

**Release note**:
```release-note
NONE
```
2017-12-13 22:26:01 -08:00
Kubernetes Submit Queue c06e7d46b5
Merge pull request #54385 from HardikDR/patch-2
Automatic merge from submit-queue (batch tested with PRs 52259, 53951, 54385, 54805, 55145). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Bugfix: Update AddNodeHandler error logs

**What this PR does / why we need it**: Its simple error log fix. Hope its not too small to be a separate PR.
2017-12-13 21:25:59 -08:00
zoues 9a47249180
typo 2017-12-10 11:11:37 +08:00
Josh Horwitz 1f840944a6 Ensure PVL controller is next pending initializer before labeling the PV 2017-12-04 23:09:11 -05:00
Ri Xu 4b71941082
Simple code and typo fixed.
Signed-off-by: Ri Xu <xuri.me@gmail.com>
2017-12-02 21:12:39 +08:00
Vladimir Vivien 7405159558 VolumeHost.GetNodeName method added for CSI fix 2017-12-02 05:54:54 -05:00
dhilipkumars 623d7c42ac Move some tests to use go sub-test 2017-12-02 13:50:35 +05:30
Maciej Szulik f760e00af7
Add job controller test verifying if backoff is reseted on success 2017-12-01 15:14:58 +01:00
Michelle Au c26debecef Return no volume match if prebound PV node affinity doesn't match node 2017-11-29 17:29:58 -08:00
pospispa e1312f2c00 Addressing Comments from Code Review
Addressing comments from code review (https://github.com/kubernetes/kubernetes/pull/55824#pullrequestreview-78597250) in order to simplify the code.
2017-11-29 15:50:23 +01:00
Josh Horwitz 04c45e10db Revert "Merge pull request #55336 from oracle/for/upstream/master/53462"
This reverts commit ccb15fb498, reversing
changes made to 4904037645.
2017-11-28 19:04:42 -05:00
Kubernetes Submit Queue 7ce780d52e
Merge pull request #56446 from ironcladlou/gc-test-flakes
Automatic merge from submit-queue (batch tested with PRs 56446, 56437). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Fix GC sync race condition

Remove faulty diff detection logic from GC sync which leads to a race
condition: If the GC's discovery client is returning a fully up to date
view of server resources during the very first GC sync, the sync
function will never sync monitors or reset the REST mapper unless
discovery changes again. This causes REST mapping to fail for any custom
types already present in discovery.

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

```release-note
NONE
```

/cc @liggitt @caesarxuchao
2017-11-28 13:08:10 -08:00
Kubernetes Submit Queue 52bd638e1a
Merge pull request #56356 from tnozicka/fix-statefulset-creating-controllerrevision-multiple-times
Automatic merge from submit-queue (batch tested with PRs 56356, 56435). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Wait for controllerrevision informer to sync on statefulset controller startup

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

Needs to be backported to at least 1.8, 1.9 and triaged for impact on 1.9 release

/cc @smarterclayton @kow3ns @enisoc 

**Release note**:
```release-note
NONE
```
2017-11-27 16:53:09 -08:00
Dan Mace a62d07ce2a Add a GC deadlock note 2017-11-27 16:50:29 -05:00
Dan Mace eeeabce831 Add more GC sync logging 2017-11-27 16:47:37 -05:00
Dan Mace 9b2886df29 Ensure sync failures are correctly retried
Only track the last synced resources when all preceding steps have
completed to ensure that failures will be correctly retried.
2017-11-27 16:29:18 -05:00
Dan Mace d89f58fcc8 Fix GC sync race condition
Remove faulty diff detection logic from GC sync which leads to a race
condition: If the GC's discovery client is returning a fully up to date
view of server resources during the very first GC sync, the sync
function will never sync monitors or reset the REST mapper unless
discovery changes again. This causes REST mapping to fail for any custom
types already present in discovery.
2017-11-27 16:11:47 -05:00
Shyam Jeedigunta 02a7e92bcf Requeue failed updates for retry in CIDR allocator 2017-11-27 12:57:29 +01:00
supereagle 032416c75d use core client with explicit version
fix more usage of deprecated core client
2017-11-25 08:14:10 +08:00
Tomas Nozicka ba6ed642a1 Wait for controllerrevision informer to sync on statefulset controller startup 2017-11-24 22:02:28 +01:00
Wojciech Tyczynski 38597a26a8 Update NetworkUnavailable condition in ipam controller 2017-11-24 12:46:22 +01:00
Shyam Jeedigunta 19e56eb42d Use PATCHs instead of PUTs in CIDR allocator 2017-11-23 21:04:28 +01:00
Kubernetes Submit Queue 028c4c9399
Merge pull request #56240 from shyamjvs/improve-cidr-allocator
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Migrate CIDR allocators to shared node informer

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

/cc @wojtek-t @bowei
2017-11-23 08:48:06 -08:00
jsafrane 4ad4ee3153 Added PVC Protection Controller
This controller removes protection finalizer from PVCs that are being
deleted and are not referenced by any pod.
2017-11-23 11:46:34 +01:00
Kubernetes Submit Queue 2f6e7bfc0d
Merge pull request #56221 from deads2k/gc-03-errors
Automatic merge from submit-queue (batch tested with PRs 52767, 55065, 55148, 56228, 56221). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

log errors while trying to GC resources

If GC can't update a finalizer, we need to see evidence of that failure.  This updates the code to log it.
2017-11-22 19:49:42 -08:00
Kubernetes Submit Queue ccb15fb498
Merge pull request #55336 from oracle/for/upstream/master/53462
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Fixes service controller update race condition

**What this PR does / why we need it**:

Fixes service controller update race condition that can happen with the node sync loop and the worker(s). This PR allows the node sync loop to utilize the same work queue as service updates so that the queue can ensure the service is being acted upon by only one goroutine. 

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #53462

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```

/cc @wlan0 @luxas @prydie @andrewsykim 

/sig cluster-lifecycle
/area cloudprovider
2017-11-22 18:05:50 -08:00
Shyam Jeedigunta 263dd1227d Migrate CIDR allocators to shared node informer 2017-11-22 22:03:03 +01:00
Kubernetes Submit Queue 6a889ec37f
Merge pull request #55039 from msau42/local-binding-4
Automatic merge from submit-queue (batch tested with PRs 51321, 55969, 55039, 56183, 55976). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Topology aware volume scheduler and PV controller changes

**What this PR does / why we need it**:
Scheduler and PV controller changes to support volume topology aware scheduling, as specified in kubernetes/community#1168

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Fixes #54435

**Special notes for your reviewer**:
* I've split the PR into logical commits to make it easier to review
* The remaining TODOs I plan to address next release unless you think it needs to be done now

**Release note**:
```release-note
Adds alpha support for volume scheduling, which allows the scheduler to make PersistentVolume binding decisions while respecting the Pod's scheduling requirements.  Dynamic provisioning is not supported with this feature yet.

Action required for existing users of the LocalPersistentVolumes alpha feature:
* The VolumeScheduling feature gate also has to be enabled on kube-scheduler and kube-controller-manager.
* The NoVolumeNodeConflict predicate has been removed.  For non-default schedulers, update your scheduler policy.
* The CheckVolumeBinding predicate has to be enabled in non-default schedulers.
```

@kubernetes/sig-storage-pr-reviews @kubernetes/sig-scheduling-pr-reviews
2017-11-22 11:59:55 -08:00
David Eads 19578eb1a1 log errors while trying to GC resources 2017-11-22 10:40:03 -05:00
supereagle 9c02d7e38c use extensions client with explicit version 2017-11-22 21:18:14 +08:00
Wojciech Tyczynski 47f756bfc5 Fix long even handler in cloud cidr allocator 2017-11-22 12:38:43 +01:00
Michelle Au a84e5b9613 update build files 2017-11-21 23:19:44 -08:00
Michelle Au fa6b62fa63 Library for scheduler volume binding 2017-11-21 21:42:36 -08:00
Michelle Au b49a1ce1a4 Cache for pod bindings 2017-11-21 21:42:36 -08:00
Michelle Au 10800e68ac Add assume cache for PVs 2017-11-21 21:42:35 -08:00
Michelle Au 58823a75a4 In findMatchingVolumes:
- Delay binding until Pod is scheduled
- Check for PV node affinity and access modes
- Exclude volumes from being matching
2017-11-21 21:42:35 -08:00
Kubernetes Submit Queue db7bb9e2ed
Merge pull request #51494 from mtanino/pr/BlockVolumesSupport-volumemanager
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Block volumes Support: CRI, volumemanager and operationexecutor changes

**What this PR does / why we need it**:
This PR contains following items to enable block volumes support feature.
- container runtime interface change
- volumemanager changes
- operationexecuto changes


**Which issue this PR fixes**:
Based on this proposal (kubernetes/community#805) and this feature issue: kubernetes/features#351

**Special notes for your reviewer**:

There are another PRs related to this functionality.
(#50457) API Change
(#53385) VolumeMode PV-PVC Binding change
(#51494) Container runtime interface change, volumemanager changes, operationexecutor changes
(#55112) Block volume: Command line printer update
Plugins
(#51493) Block volumes Support: FC plugin update
(#54752) Block volumes Support: iSCSI plugin update

**Release note**:
```
Adds alpha support for block volume, which allows the users to attach raw block volume to their pod without filesystem on top of the volume.
```
/cc @msau42 @liggitt @jsafrane @saad-ali @erinboyd @screeley44
2017-11-21 19:43:27 -08:00
Michelle Au 3d0b510e25 Refactor bindVolumeToClaim() into 1) forming new PV object 2) making API and cache update 2017-11-21 19:11:36 -08:00
Michelle Au 3211b8b0c4 Refactor PV selection into a common call for scheduler and PV controller 2017-11-21 19:11:36 -08:00
Kubernetes Submit Queue d5bc9a4164
Merge pull request #56168 from screeley44/fix-toggle-bug
Automatic merge from submit-queue (batch tested with PRs 55340, 55329, 56168, 56170, 56105). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

fixing issue of feature gate not being turned off properly

Fixes #56166 

Adding proper defer and toggle of feature gate for BlockVolume support
2017-11-21 18:56:34 -08:00
Kubernetes Submit Queue 5ac4f172f9
Merge pull request #55329 from kow3ns/sts-name-label
Automatic merge from submit-queue (batch tested with PRs 55340, 55329, 56168, 56170, 56105). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Sts per Pod Name Label

**What this PR does / why we need it**:
StatefulSet controller will add a label for each Pod in the StatefulSet. The label is of the form 
`statefulset.kubernetes.io/pod-name: <pod.Name>`. This allows a unique service to be created for each Pod in the StatefulSet.

Fixes  #44103, #28660


```release-note
StatefulSet controller will create a label for each Pod in a StatefulSet. The label is named statefulset.kubernetes.io/pod-name and it is equal to the name of the Pod. This allows users to create a Service per Pod to expose a connection to individual Pods.
```
2017-11-21 18:56:31 -08:00
Scott Creeley 74fcd97c84 fixing issue of feature gate not being turned off properly 2017-11-21 15:19:18 -05:00
Kubernetes Submit Queue c98aabccb0
Merge pull request #53907 from mikedanese/base-delay
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

sarapprover: increase base delay of per item rate limit

from 5 miliseconds to 1 second

fixes https://github.com/kubernetes/kubernetes/issues/53734
2017-11-21 09:44:17 -08:00
Kubernetes Submit Queue 1d7f7eaf8d
Merge pull request #53385 from screeley44/binding-volumetype
Automatic merge from submit-queue (batch tested with PRs 55938, 56055, 53385, 55796, 55922). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

VolumeMode binding logic update

Adds VolumeMode binding logic to pv-controller for local block support based on this proposal (kubernetes/community#805) and this feature issue: kubernetes/features#351

**Special notes for your reviewer:**
this change is dependent on #50457 

cc @msau42 @jsafrane @mtanino @erinboyd
2017-11-21 07:43:46 -08:00
Slava Semushin 2b86881ab3 pkg/controller/garbagecollector/garbagecollector.go: fix string format. 2017-11-21 15:24:34 +01:00
Scott Creeley 86742a2c92 VolumeMode binding logic update 2017-11-20 15:18:19 -05:00
Mitsuhiro Tanino 9329dd5b91 generated code for Volumemanager change 2017-11-20 14:10:34 -05:00
mtanino 8903e8cd85 BlockVolumesSupport: CRI, VolumeManager and OperationExecutor changes
This patch contains following changes.
- container runtime changes for adding block devices
- volumemanager changes
- operationexecutor changes
2017-11-20 14:10:26 -05:00
Kubernetes Submit Queue d0301aa6e8
Merge pull request #54208 from resouer/rm-alpha
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Move of unreachable taint key out of alpha

**What this PR does / why we need it**:

Move of unreachable taint key out of alpha, which already happened in community doc.

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #54198

**Special notes for your reviewer**:
Please see #54198 for the context of this inconsistency.

**Release note**:

```release-note
Move unreachable taint key out of alpha. 
Please note the existing pods with the alpha toleration should be updated by user himself to tolerate the GA taint.
```
2017-11-20 10:50:17 -08:00
Kenneth Owens 1ce4ef8229 Adds the statefulset.kubernetes.io/pod-name label allowing users to
attach a Service to an individual Pod.
2017-11-20 09:13:07 -08:00
Kubernetes Submit Queue bf32170dca
Merge pull request #54701 from mattjmcnaughton/mattjmcnaughton/53728-clean-up-reconcileAutoscaling
Automatic merge from submit-queue (batch tested with PRs 55974, 54701). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Refactor `reconcileAutoscaler` method in hpa

**What this PR does / why we need it**:

There have been a couple of recent bugs in the "normalizing" part of the
`reconcileAutoscaler` method. This part of the code base is responsible
for, among other things, taking the suggested desired replicas based on
the metrics, ensuring it conforms to certain conditions, and updating it
if it does not. Isolate the part that converts the desired replicas
based on a given set of rules into its own function.

We are refactoring this part of the code base to make the logic simpler
and to make it easier to write unit tests.

**Which issue this PR fixes**: 
Fixes #53728

**Release note**:
```release-note
NONE
```
2017-11-20 08:16:26 -08:00
Kubernetes Submit Queue 69098ad7b3
Merge pull request #55653 from hzxuzhonghu/test-flaky
Automatic merge from submit-queue (batch tested with PRs 55908, 55829, 55293, 55653, 55665). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

[bug fix] TestCascadingDeletion during pull-kubernetes-unit-test flaky

**What this PR does / why we need it**:
fix pull-kubernetes-unit-test flaky.

```
go test -v k8s.io/kubernetes/test/integration/garbagecollector -run TestCascadingDeletion$
panic: close of closed channel
/go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/util/runtime/runtime.go:58 +0x111
/usr/local/go/src/runtime/panic.go:491 +0x283
/go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/pkg/controller/garbagecollector/graph_builder.go:259 +0xb80
/go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/pkg/controller/garbagecollector/garbagecollector.go:123 +0x39
/go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/pkg/controller/garbagecollector/garbagecollector.go:211 +0x20f
/go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/util/wait/wait.go:133 +0x5e
/go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/util/wait/wait.go:134 +0xbd
/go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/util/wait/wait.go:88 +0x4d
/go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/pkg/controller/garbagecollector/garbagecollector.go:172 +0xd9
/go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/test/integration/garbagecollector/garbage_collector_test.go:268 +0xc9
				from junit_3a3d564eebb1750e5c904cc525d117617fc0af51_20171113-090812.xml
```

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Fixes #55652

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-11-17 17:11:13 -08:00
Kubernetes Submit Queue 66d1401cb5
Merge pull request #55293 from xiangpengzhao/up-go-19-change
Automatic merge from submit-queue (batch tested with PRs 55908, 55829, 55293, 55653, 55665). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Use go native func after upgrading to go1.9

**What this PR does / why we need it**:
Since we have already upgraded to go1.9 (#51375), use go native func after upgrading to go1.9.

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
ref: #52033

**Special notes for your reviewer**:
/cc @aanm @bowei 

**Release note**:

```release-note
NONE
```
2017-11-17 17:11:11 -08:00
Harry Zhang df8c92ac12 Replace node's alpha taint key with GA 2017-11-17 15:35:35 +08:00
hzxuzhonghu fbf81bc7ad fix underlying bug: double close channel when stop 2017-11-17 10:35:03 +08:00
Kubernetes Submit Queue b79e3d14d1
Merge pull request #55772 from liggitt/gc-ignored-resources
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Only attempt to construct GC informers for watchable resources

A resource must support list/watch in addition to delete for an informer to be functional

Exclude resources that are not watchable from informer construction

Also fixes a bug with the graph builder not using the instance-configured list of ignored resources

/assign @ironcladlou

```release-note
NONE
```
2017-11-16 15:16:16 -08:00
Mike Danese 0e0f8346e7 sarapprover: increase base delay of per item rate limit
from 5 miliseconds to 1 second
2017-11-16 11:27:06 -08:00
Mike Danese 302fe7c0c8 sarapprover: ignore authz errors 2017-11-16 11:27:05 -08:00
mattjmcnaughton e74838b6ab Refactor `reconcileAutoscaler` method in hpa
There have been a couple of recent bugs in the "normalizing" part of the
`reconcileAutoscaler` method. This part of the code base is responsible
for, among other things, taking the suggested desired replicas based on
the metrics, ensuring it conforms to certain conditions, and updating it
if it does not. Isolate the part that converts the desired replicas
based on a given set of rules into its own function.

We are refactoring this part of the code base to make the logic simpler
and to make it easier to write unit tests.
2017-11-16 09:42:49 -05:00
Kubernetes Submit Queue 817e8a2e43
Merge pull request #55758 from wackxu/updateService
Automatic merge from submit-queue (batch tested with PRs 55657, 54758, 47584, 55758, 55651). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

WaitForCacheSync fail should return for service controller

**What this PR does / why we need it**:

1. WaitForCacheSync fail should return for service controller as other controller
2. remove unused function
3. fix several weak error follow up #54280 according to https://github.com/golang/go/wiki/CodeReviewComments#error-strings

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Fixes #

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-11-15 23:57:31 -08:00
Kubernetes Submit Queue 74369ea44c
Merge pull request #55683 from gregory-m/remove-unnecessary-conversion
Automatic merge from submit-queue (batch tested with PRs 55764, 55683, 55468, 54409, 55546). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Removed unnecessary type conversion

nodeName is string variable and it unnecessary to convert it to string.

```release-note
NONE
```
2017-11-15 22:15:56 -08:00
Kubernetes Submit Queue 9c08d30412
Merge pull request #55681 from gregory-m/remove-unused-code
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Removed unused function.

Removed unused int64P function from controller_utils_test.go

**Release note**:
```release-note
NONE
```
2017-11-15 14:30:42 -08:00
wackxu ead429ebda WaitForCacheSync fail should return for service controller 2017-11-15 21:08:07 +08:00
Jordan Liggitt dbfc43f723
Only attempt to construct GC informers for watchable resources 2017-11-15 02:26:58 -05:00
Guangya Liu 4d56bc34bd NC should log the whole node condition. 2017-11-14 17:35:09 +08:00
Cao Shufeng 86968e44d0 remove duplicated import 2017-11-14 17:18:17 +08:00
Gregory Man 62923517fa Removed unnecessary type conversion
nodeName is string variable and it unnecessary to convert it to string.
2017-11-14 11:04:18 +02:00
Gregory Man ac8216027a Removed unused function.
Removed unused int64P function from controller_utils_test.go
2017-11-14 10:53:29 +02:00
David Eads e52383c486 add clusterrole aggregation controller 2017-11-13 08:18:00 -05:00
David Eads a53e5de3db generated 2017-11-13 08:18:00 -05:00
Kubernetes Submit Queue 1e9204ba44
Merge pull request #55144 from houjun41544/20171106
Automatic merge from submit-queue (batch tested with PRs 54987, 55221, 54099, 55144, 54215). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Should not sync the volume when  claim.Spec.VolumeName is null 

**What this PR does / why we need it**:

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Fixes #

**Special notes for your reviewer**:

**Release note**:

```release-note

```
2017-11-10 14:51:30 -08:00
Dr. Stefan Schimanski 1e79dfb959 Update generated code 2017-11-10 18:26:46 +01:00
Kubernetes Submit Queue 9ed5d380aa
Merge pull request #45792 from rpothier/cidr_allocator_ipv6
Automatic merge from submit-queue (batch tested with PRs 46946, 45792). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Updating NewCIDRSet return a value

**What this PR does / why we need it**:
Updating NewCIDRSet return value
    
For IPv6, NewCIDRSet was updated to return an error if the subnet mask size
is too big. In this case, NewCIDRSet will fail and return an error.



**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #52348

**Special notes for your reviewer**:


**Release note**:

```release-note
```
2017-11-09 11:27:48 -08:00