Commit Graph

243 Commits (b038355c81ee621ef0bb199c20442879b97eadc1)

Author SHA1 Message Date
Kubernetes Submit Queue ac266ae85b Merge pull request #29939 from mwielgus/federated_informer
Automatic merge from submit-queue

Federation - common libs - FederatedInformer

Fixes #29383

Will add more tests after the first pass of the review.

ref: #29347

cc: @nikhiljindal @wojtek-t
2016-08-03 13:43:37 -07:00
Marcin Wielgus 040203b40a Federation - common libs - FederatedInformer 2016-08-03 17:53:05 +02:00
Kubernetes Submit Queue 503f5afe1a Merge pull request #29858 from xiangpengzhao/delete-useless-code
Automatic merge from submit-queue

Delete useless code

The correct code is `cluster, ok := obj.(*v1beta1.Cluster)`, so the above `cluster := obj.(*v1beta1.Cluster)` is useless.
2016-08-02 23:36:31 -07:00
Madhusudan.C.S 31f5525f43 Revert "[Federation] Downsize the release binary distribution." 2016-08-01 23:54:09 -07:00
k8s-merge-robot 37d3d390df Merge pull request #29632 from madhusudancs/fed-bin-downsize
Automatic merge from submit-queue

[Federation] Downsize the release binary distribution.

There are two things that this PR implements:

1. It removes `federation-apiserver` and `federation-controller-manager` from binaries and docker_wrapped_binaries target lists.
2. Build the docker image for `hyperkube` on-the-fly while pushing the federation images. 

```release-note
Federation binaries and their corresponding docker images - `federation-apiserver` and `federation-controller-manager` are now folded in to the `hyperkube` binary. If you were using one of these binaries or docker images, please switch to using the `hyperkube` version. Please refer to the federation manifests - `federation/manifests/federation-apiserver.yaml` and `federation/manifests/federation-controller-manager-deployment.yaml` for examples.
```

cc @kubernetes/sig-cluster-federation @colhom 

Fixes Issue #28633
2016-08-01 22:55:46 -07:00
Madhusudan.C.S b5bea93954 Build the hyperkube docker image on-the-fly.
This is only a temporary fix until the proposal in issue
https://github.com/kubernetes/kubernetes/issues/28630 is implemented.

Also, the new build/deployment method completely obviates this step.
2016-08-01 11:45:21 -07:00
Madhusudan.C.S 5a3a84968b [Federation] Do not build separate binaries for federation control plane components, hyperkube should be sufficient. 2016-08-01 11:45:21 -07:00
xiangpengzhao 14adb38018 Delete useless code 2016-08-01 13:00:46 -04:00
Harry Zhang c495397cae Refactor uuid into its own pkg 2016-07-30 00:07:02 -04:00
k8s-merge-robot 7e3246d415 Merge pull request #29788 from xiangpengzhao/fix-clientRetryCount
Automatic merge from submit-queue

Keep retry times the same for each place where trying to ensure DNS Records

There are three places where ensureDnsRecords is retried. But they have different retry times. One place [(here)](https://github.com/xiangpengzhao/kubernetes/blob/master/federation/pkg/federation-controller/service/endpoint_helper.go#L107) is clientRetryCount but other two [(here](https://github.com/xiangpengzhao/kubernetes/blob/master/federation/pkg/federation-controller/service/endpoint_helper.go#L138) and [here)](https://github.com/xiangpengzhao/kubernetes/blob/master/federation/pkg/federation-controller/service/endpoint_helper.go#L161) are clientRetryCount + 1. Though this case doesn't have any influence, shouldn't we keep retry times the same each place?

also fix other nits:
use the same log level.
log the error in each loop.

cc @quinton-hoole
2016-07-29 13:33:14 -07:00
k8s-merge-robot 0693d47987 Merge pull request #29241 from jianhuiz/federation-apiserver-extensions-replicaset-client
Automatic merge from submit-queue

Generate federation apiserver extensions replicaset client

generate clientset for extensions/ReplicaSet of federation apiserver

@nikhiljindal @quinton-hoole, @deepak-vij
#24764
2016-07-29 11:40:12 -07:00
xiangpengzhao 60798e7c48 Keep retry times the same for each place where ensureDnsRecords is called. 2016-07-29 12:30:27 -04:00
k8s-merge-robot 2817674715 Merge pull request #29557 from deads2k/make-prefx-configurable
Automatic merge from submit-queue

make the resource prefix in etcd configurable for cohabitation

This looks big, its not as bad as it seems.

When you have different resources cohabiting, the resource name used for the etcd directory needs to be configurable.  HPA in two different groups worked fine before.  Now we're looking at something like RC<->RS.  They normally store into two different etcd directories.  This code allows them to be configured to store into the same location.

To maintain consistency across all resources, I allowed the `StorageFactory` to indicate which `ResourcePrefix` should be used inside `RESTOptions` which already contains storage information.

@lavalamp affects cohabitation.
@smarterclayton @mfojtik prereq for our rc<->rs and d<->dc story.
2016-07-28 03:01:28 -07:00
k8s-merge-robot 313272a22c Merge pull request #29508 from k82cn/add_whitspace
Automatic merge from submit-queue

Remove unnecessary empty line.
2016-07-27 19:52:47 -07:00
deads2k aa3db4d995 make the resource prefix in etcd configurable for cohabitation 2016-07-27 07:51:40 -04:00
k8s-merge-robot d038e22d87 Merge pull request #28062 from colhom/add-colhom-federation-owners
Automatic merge from submit-queue

Add colhom to federation OWNERS

Depends on #28042

\cc @quinton-hoole 

[![Analytics](https://kubernetes-site.appspot.com/UA-36037335-10/GitHub/.github/PULL_REQUEST_TEMPLATE.md?pixel)]()
2016-07-25 17:33:24 -07:00
k8s-merge-robot e7db6687fc Merge pull request #29455 from mwielgus/frsc-scheduling
Automatic merge from submit-queue

Replica location planner for Federated ReplicaSet Controller

Requires #29385 to be merged.

cc: @quinton-hoole @wojtek-t
2016-07-25 16:16:11 -07:00
Klaus Ma 53b94e16d0 Remove unnecessary empty line. 2016-07-23 19:37:13 +08:00
Marcin Wielgus ed92579d2e Replica location planner for Federated ReplicaSet Controller 2016-07-23 02:04:33 +02:00
k8s-merge-robot eaf3d3f708 Merge pull request #28668 from justinsb/update_dns
Automatic merge from submit-queue

Expose Changesets (transactions) in dns provider

This makes the dnsprovider usable in more scenarios, and it also solves
some TODOs in the federation code.

WIP  - I'm going to test this to make sure this both works and is sufficient for use in my dns controller, but I wanted to put some code behind the talk in #28477.  cc @quinton-hoole 

Issue #28477
2016-07-22 16:25:22 -07:00
k8s-merge-robot 7626539683 Merge pull request #29385 from mwielgus/federated-rs-pref
Automatic merge from submit-queue

API types for FederatedReplicaSetPreferences

Currently only internal types just to unblock the work on scheduling part of Federated Replica Set Controller.
2016-07-22 15:35:13 -07:00
Marcin Wielgus 944e7f77b0 Internal types for FederatedReplicaSetPreferences 2016-07-22 23:35:38 +02:00
Justin Santa Barbara 756c17315b Fix route53 stub matching logic: match name & type 2016-07-22 15:09:04 -04:00
k8s-merge-robot df2cf16ddb Merge pull request #26709 from hodovska/master
Automatic merge from submit-queue

Allow shareable resources for admission control plugins.

Changes allow admission control plugins to share resources. This is done via new PluginInitialization structure. The structure can be extended for other resources, for now it is an shared informer for namespace plugins (NamespiceLifecycle, NamespaceAutoProvisioning, NamespaceExists).

If a plugins needs some kind of shared resource e.g. client, the client shall be added to PluginInitializer and Wants methods implemented to every plugin which will use it.
2016-07-22 11:07:05 -07:00
Justin Santa Barbara 6463a220ee Expose Changesets (transactions) in dns provider
This makes the dnsprovider usable in more scenarios, and it also solves
some TODOs in the federation code.
2016-07-22 08:43:20 -04:00
k8s-merge-robot f7409f3be2 Merge pull request #29368 from mwielgus/delaying_deliverer
Automatic merge from submit-queue

Delaying deliverer for Federated ReplicaSet

A helper struct to push data to a channel after a given delay. It runs on a single gouroutine and allows updates. An update cancels previous delivery if it was about to happen later than the new one. Otherwise the new update is discarded. 
All data require a string key that is used to identify the data (for updates and de-duplication).

cc: @quinton-hoole @wojtek-t
2016-07-22 01:13:57 -07:00
k8s-merge-robot 72a697a13d Merge pull request #28182 from quinton-hoole/2016-06-28-compare-rrsets-properly
Automatic merge from submit-queue

Federation: Use equivalent() instead of == to compare DNS ResourceRecordSets. Fixes #28135

Without this we sometimes incorrectly assume that DNS records hosted on cloud DNS servers need to be replaced when they don't need to be.  This results in unnecessary churn on DNS records.

cc: @nikhiljindal @madhusudancs @mfanjie FYI
2016-07-22 00:41:06 -07:00
jianhuiz e105833660 add generated federation clientsets for extensions/ReplicaSet 2016-07-21 14:00:35 -07:00
Madhusudan.C.S 31e09d326d Add "federation" API group to the known versions list of federation API clients. 2016-07-21 11:55:44 -07:00
Marcin Wielgus 85dd375cc8 Delaying deliverer for Federated ReplicaSet 2016-07-21 16:49:16 +02:00
Dominika Hodovska 037d116add Factory for SharedIndexInformers 2016-07-21 14:04:48 +02:00
Quinton Hoole 3dd1c0088e Use ResourceRecordSetsEquivalent() instead of == to compare rrsets. Fixes #28135 2016-07-20 15:49:19 -07:00
nikhiljindal 11ba8943fe Updating federation controllers to use release_1_4 clientset instead of release_1_3 clientset 2016-07-20 10:56:57 -07:00
Dominika Hodovska ba40a528e1 PluginInitializer as a new part of NewFromPlugins method 2016-07-20 12:53:52 +02:00
Dominika Hodovska fc0a3c6dcb Allow shareable resources for admission control plugins 2016-07-20 12:53:52 +02:00
k8s-merge-robot c305c39bcb Merge pull request #28938 from madhusudancs/fed14-kubeconfig-secret-name
Automatic merge from submit-queue

Change the name of the secret that delivers federation kubeconfig.

```release-note
Federation API server kubeconfig secret consumed by federation-controller-manager has a new name.

If you are upgrading your Cluster Federation components from v1.3.x, please run this command to migrate the federation-apiserver-secret to federation-apiserver-kubeconfig serect;

$ kubectl --namespace=federation get secret federation-apiserver-secret -o json | sed 's/federation-apiserver-secret/federation-apiserver-kubeconfig/g' | kubectl create -f -

You might also want to delete the old secret using this command:

$ kubectl delete secret --namespace=federation federation-apiserver-secret
```

The current name, federation-apiserver-secret, is very similar to the
other secret we have, federation-apiserver-secrets, that delivers
somewhat similar data but in a different format. This is extremely
confusing, particularly while debugging.

This change should soothe the pain.

cc @kubernetes/sig-cluster-federation
2016-07-19 23:50:15 -07:00
k8s-merge-robot 4d896cd3b2 Merge pull request #29008 from justinsb/pages_and_pages_of_hosted_zones
Automatic merge from submit-queue

dnsprovider: Use route53 page functions to avoid truncated results

The List<Type>Pages functions make it pretty easy to avoid result truncation;
switch to using them
2016-07-19 20:29:44 -07:00
k8s-merge-robot d34c3fa328 Merge pull request #24764 from XiaoningDing/federation-apiserver-extensions-replicaset
Automatic merge from submit-queue

Add extensions/replicaset to federation-apiserver

Add extensions/replicaset for federated scheduler (#24038) as all k8s api objects were removed in #23959

Please review only the very last one commit.

#19313 #23653 
@nikhiljindal @quinton-hoole, @deepak-vij, @XiaoningDing, @alfred-huangjian @mfanjie @huangyuqi @colhom
2016-07-19 15:51:54 -07:00
Madhusudan.C.S 3ac2ab39b8 Change the name of the secret that delivers federation kubeconfig.
The current name, federation-apiserver-secret, is very similar to the
other secret we have, federation-apiserver-secrets, that delivers
somewhat similar data but in a different format. This is extremely
confusing, particularly while debugging.

This change should soothe the pain.
2016-07-19 12:27:33 -07:00
Madhusudan.C.S 74cf837005 Fix a typo in my Github username [madhusudancs]. 2016-07-19 11:51:45 -07:00
jianhuiz bf3e1a5f97 register extensions/replicasets to federated-apiserver 2016-07-19 10:42:03 -07:00
k8s-merge-robot c25262b951 Merge pull request #26298 from nikhiljindal/createFedService
Automatic merge from submit-queue

federation: Adding namespaces API

Adding namespaces API to federation-apiserver and updating the federation client to include namespaces


--------------------------

Original description:

This adds the namespaces API to federation-apiserver.

The first commit is https://github.com/kubernetes/kubernetes/pull/26142.
2016-07-19 09:22:11 -07:00
k8s-merge-robot 4466531382 Merge pull request #29094 from luxas/gomaxproc
Automatic merge from submit-queue

Remove GOMAXPROCS() calls because they are unnecessary


Now we're setting GOMAXPROCS when every binary starts up, but we don't have to do that anymore, since we've upgraded to Go 1.6

Documentation for it:

> func GOMAXPROCS(n int) int

> GOMAXPROCS sets the maximum number of CPUs that can be executing simultaneously and returns the previous setting. If n < 1, it does not change the current setting. The number of logical CPUs on the local machine can be queried with NumCPU. This call will go away when the scheduler improves. 

A simple program to prove it's unnecessary:

```go
package main
import (
    "fmt"
    "runtime"
)
func main(){
    numCPUBefore := runtime.GOMAXPROCS(runtime.NumCPU())
    numCPUAfter := runtime.GOMAXPROCS(runtime.NumCPU())
    fmt.Println(numCPUBefore, numCPUAfter)
}
```

Output with Go 1.4.2: `1 4`
Output with Go 1.6.2: `4 4`

So I think we should remove calls to GOMAXPROCS now, and it should be pretty straightforward

@thockin @wojtek-t @gmarek @lavalamp @vishh
2016-07-19 08:11:24 -07:00
nikhiljindal 48658ad94d Adding namespace expansion files 2016-07-19 07:38:58 -07:00
nikhiljindal 7b664cff47 Updating the federation clientset to include namespaces 2016-07-19 07:38:58 -07:00
nikhiljindal a0f96fc973 Adding namespaces to federation-apiserver 2016-07-19 07:38:58 -07:00
k8s-merge-robot 9344f2ca89 Merge pull request #29123 from madhusudancs/fed-fix-post-dontcheckingconversiongen
Automatic merge from submit-queue

Register the federation core API conversion and default functions.

This was removed by mistake in 9eb42f (PR #25978). Reverting some
of those changes and adding the new mechanism to autogenerate
conversions for the new types that we might define in this API
group in the future.

cc @kubernetes/sig-cluster-federation 

@thockin @lavalamp please take a look at this once even if the PR merges before you get a chance to take a look.

@thockin particularly see the `federation/apis/core/v1/doc.go` file.

Fixes issue #28615
2016-07-19 05:42:39 -07:00
Lucas Käldström 88ea80b572 Remove GOMAXPROCS() calls because they are unnecessary 2016-07-19 11:08:21 +03:00
Madhusudan.C.S 0072766c41 Register the federation core API conversion and default functions.
This was removed by mistake in 9eb42f (PR #25978). Reverting some
of those changes and adding the new mechanism to autogenerate
conversions for the new types that we might define in this API
group in the future.
2016-07-18 15:10:41 -07:00
k8s-merge-robot fa174bcdaf Merge pull request #29042 from dims/fixup-imports
Automatic merge from submit-queue

Use Go canonical import paths

Add canonical imports only in existing doc.go files.
https://golang.org/doc/go1.4#canonicalimports

Fixes #29014
2016-07-18 07:23:38 -07:00