Commit Graph

41 Commits (4c874dbefe2bd1f06a9358146be106c87b4858ce)

Author SHA1 Message Date
Walter Fender f3f46d5f5a Moving the cloudprovider interface to staging.
Individual implementations are not yet being moved.
Fixed all dependencies which call the interface.
Fixed golint exceptions to reflect the move.
Added project info as per @dims and
https://github.com/kubernetes/kubernetes-template-project.
Added dims to the security contacts.
Fixed minor issues.
Added missing template files.
Copied ControllerClientBuilder interface to cp.
This allows us to break the only dependency on K8s/K8s.
Added TODO to ControllerClientBuilder.
Fixed GoDeps.
Factored in feedback from JustinSB.
2018-10-04 14:41:20 -07:00
yankaiz 267252d9e1 Let the service controller retry when presistUpdate returns a conflict error. 2018-09-04 15:34:26 -07:00
morrislaw 6ecec23690 Implement GetLoadBalancerName per provider and add DefaultLoadBalancerName. 2018-08-04 00:36:48 -04:00
yue9944882 dc07e4dcba fixes docs 2018-06-28 11:33:47 +08:00
Mikhail Mazurskiy 468655b76a
Use typed events client directly 2018-04-01 18:57:29 +10:00
zhangxiaoyu-zidif 44aeb56eab fix nodenames slices comparison para. 2018-02-27 15:54:45 +08:00
Walter Fender e18e8ec3c0 Add context to all relevant cloud APIs
This adds context to all the relevant cloud provider interface signatures.
Callers of those APIs are currently satisfied using context.TODO().
There will be follow on PRs to push the context through the stack.
For an idea of the full scope of this change please look at PR #58532.
2018-02-06 12:49:17 -08:00
lichuqiang f6201c4ffa fix event message when processing loadbalancer update 2018-01-19 10:48:30 +08:00
Kubernetes Submit Queue 408a316b1d
Merge pull request #56370 from oracle/for/upstream/master/55528
Automatic merge from submit-queue (batch tested with PRs 57868, 58284, 56370, 58400, 58439). 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 service controller to common controller pattern

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

The service controller currently uses a non-standard controller pattern that adds unneeded complexity. This PR moves the service controller to use common tools like the rate limited queue with exponential backoff versus tracking retry backoff in the cachedService object. 

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

**Special notes for your reviewer**:

This does change the retry backoff from a linear backoff to an exponential backoff. The min and max retry delay stays the same. 

There was only one case where we didn't want to retry, which was when we updated the service status since that handled retries itself. In that case I moved to the common pattern of using `runtime.HandleError`.

**Release note**:

```release-note
NONE
```

/cc @luxas @wlan0 @andrewsykim @thockin 
@prydie 

/sig cluster-lifecycle
/sig networking
/kind cleanup
2018-01-18 13:11:34 -08:00
zhangxiaoyu-zidif b12c3b8660 use sets.String to replace slice when sort []string 2018-01-06 16:16:37 +08:00
Josh Horwitz ffba27d72e Refactor service controller to common controller pattern 2017-12-19 23:08:48 -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
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 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
wackxu ead429ebda WaitForCacheSync fail should return for service controller 2017-11-15 21:08:07 +08:00
Dr. Stefan Schimanski 012b085ac8 pkg/apis/core: mechanical import fixes in dependencies 2017-11-09 12:14:08 +01:00
Josh Horwitz c8a12b8045 Fixes service controller update race condition 2017-11-08 21:57:51 -05:00
Ferran Rodenas d67898b875 Check RegisterMetricAndTrackRateLimiterUsage error when starting controllers
Signed-off-by: Ferran Rodenas <rodenasf@vmware.com>
2017-11-01 12:46:07 +01:00
Kubernetes Submit Queue cadcb62065
Merge pull request #54644 from brendandburns/node-label
Automatic merge from submit-queue (batch tested with PRs 54644, 53072). 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>.

Flag gate node exclusion for service load balancers.

@thockin @jdumars 

```release-note
Add a new feature gate for enabling an alpha annotation which, if present, excludes the annotated node from being added to a service load balancers.
```

Issue: https://github.com/kubernetes/kubernetes/issues/54743

Notes:
The original PR for this feature was: https://github.com/kubernetes/kubernetes/pull/53146

Which didn't include a gate (or the alpha label).

This was refined to add the `alpha` label in:
https://github.com/kubernetes/kubernetes/pull/53678

Then in the cherry-pick review:
https://github.com/kubernetes/kubernetes/pull/53656#issuecomment-335693646

@thockin requested a gate for an alpha feature, which is this PR.
2017-10-28 07:26:24 -07:00
Brendan Burns a71f757148 wqFlag gate node exclusion for service load balancers. 2017-10-28 03:44:46 +00:00
Kevin 4c8539cece use core client with explicit version globally 2017-10-27 15:48:32 +08:00
Kubernetes Submit Queue 8f505e4c86 Merge pull request #54341 from athampy/gh-54339
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>.

Remove redundant call to StartLogging in service_controller. Fixes #5…

…4339



**What this PR does / why we need it**:
Removes redundant call to StartLogging introduced in 96b48d4#diff-1f7f903e25ab8bcbc514bb1e532e997e

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

**Special notes for your reviewer**:

**Release note**:

```release-note
```
2017-10-25 13:22:50 -07:00
Kubernetes Submit Queue 01374839b0 Merge pull request #53196 from FengyunPan/lb-empty-node
Automatic merge from submit-queue (batch tested with PRs 52868, 53196, 54207). 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>.

Check the count of cloud node for LoadBalancer service

If there is no available node for LoadBalancer service, the LoadBlancer
service will become unavailable, we should update service status.
This is part of #53193
**What this PR does / why we need it**:

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

**Special notes for your reviewer**:

**Release note**:
```release-note
NONE
```
2017-10-25 12:32:18 -07:00
Kubernetes Submit Queue ee9983355e Merge pull request #54500 from MrHohn/service-controller-more-logging
Automatic merge from submit-queue (batch tested with PRs 54366, 54500). 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>.

Service controller / gce loadbalancer logging cleanup

**What this PR does / why we need it**:
From https://github.com/kubernetes/kubernetes/issues/52495, while looking into the potential scalability issue service controller may have, I found it really hard to debug as the log sometimes doesn't reference which LB it is for, or sometimes it just doesn't log at all. It get even harder that in correctness CIs we reduce verbose level to v1:
67bc30718f/jobs/env/ci-kubernetes-e2e-gce-scale-correctness.env (L16).

**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**:
/assign @nicksardo @bowei 
cc @shyamjvs 

**Release note**:

```release-note
NONE
```
2017-10-24 16:54:02 -07:00
Kubernetes Submit Queue 4ca155cbc1 Merge pull request #54184 from MrHohn/fix-service-controller-retry
Automatic merge from submit-queue (batch tested with PRs 54107, 54184, 54377, 54094, 54111). 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 retry logic in service controller

**What this PR does / why we need it**: Make service controller don't retry on doNotRetry service update failure.

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

**Special notes for your reviewer**:
/assign @nicksardo @bowei 

**Release note**:

```release-note
NONE
```
2017-10-24 15:59:06 -07:00
Zihong Zheng e3eac372f0 service_controller: Include service key in error messages 2017-10-24 10:51:15 -07:00
Akhil Thampy 572b1c2db9 Remove redundant call to StartLogging in service_controller. Fixes #54339 2017-10-21 11:45:48 -05:00
FengyunPan 3cf89a5de7 Check the count of cloud node for LoadBalancer service
If there is no available node for LoadBalancer service, the LoadBlancer
service will become unavailable, we should update service status.
This is part of #53193
2017-10-20 12:04:02 +08:00
hzxuzhonghu 96b48d4386 add event broadcaster logging for all contoller managers 2017-10-19 09:18:43 +08:00
Zihong Zheng 72542f5b82 Fix retry logic in service controller 2017-10-18 16:58:19 -07:00
Davanum Srinivas eda7fbd16a Ignore .import-restrictions when checking against generated docs 2017-10-13 07:09:38 -04:00
Davanum Srinivas a4574bbb04 Make sure pkg/controller/service does not depend on cmd/kubeadm/app 2017-10-13 07:06:21 -04:00
Kubernetes Submit Queue 182aa93be8 Merge pull request #53487 from oracle/for/upstream/master/service-event-logging
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>.

Enable event logging in the service controller

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

This PR enables logging for the events in the service controller which keeps parity with the [node controller](https://github.com/kubernetes/kubernetes/blob/master/pkg/controller/cloud/node_controller.go#L83).

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

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```

/cc @luxas @wlan0 @jhorwit2
2017-10-06 09:56:19 -07:00
Josh Horwitz 36ac3c8c31 Enable event logging in the service controller 2017-10-05 10:37:14 +01:00
Brendan Burns 422f5e37b9 Add a label which prevents a node from being added to a cloud load balancer. 2017-09-27 10:13:02 -07:00
Dr. Stefan Schimanski 1d053c4f7c controllers: simplify deepcopy calls 2017-08-29 19:21:24 +02:00
Kubernetes Submit Queue 5a76d7ab63 Merge pull request #50539 from brendandburns/svc
Automatic merge from submit-queue (batch tested with PRs 51108, 51035, 50539, 51160, 50947)

Delete load balancers if the UIDs for services don't match.

An attempt to fix https://github.com/kubernetes/kubernetes/issues/43730

@thockin @djsly
2017-08-24 02:32:09 -07:00
du c9941ff4d2 fix confusion in service_controller
remove worthless comment line
2017-08-22 20:14:18 +08:00
Brendan Burns 813d264c86 Delete load balancers if the UIDs for services don't match. 2017-08-11 22:28:41 -07:00
Yassine TIJANI a532784189 simplify logic around LB deletion 2017-08-08 12:51:45 +02:00
dhilipkumars a1ba598130 Have a uniform format for filenames across controllers 2017-08-02 09:50:05 +05:30