Commit Graph

144 Commits

Author SHA1 Message Date
Kubernetes Publisher 4176c80429 Merge pull request #50681 from sttts/sttts-deepcopy-calls-apiserver
Automatic merge from submit-queue

apiserver: simplify deepcopy calls

Kubernetes-commit: 2d5624bb2c36e1918afd5d953275c5fae7e1ffd3
2017-08-29 13:16:13 +00:00
Kubernetes Publisher 10e9a53d92 Merge pull request #50553 from m1093782566/fed-kube-apiserver
Automatic merge from submit-queue (batch tested with PRs 49129, 50436, 50417, 50553, 47587)

add validation for fed-apiserver and apiserver run options

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

Add validation for fed-apiserver and apiserver run options

**Which issue this PR fixes**

fixes #50552

**Special notes for your reviewer**:

This is a follow-up of #50135

**Release note**:

```release-note
NONE
```

Kubernetes-commit: f9c861aa101b16a09dd10def70756dbb0b054868
2017-08-29 13:16:11 +00:00
Kubernetes Publisher e82277a8ca Merge pull request #50094 from sttts/sttts-no-importprefix
Automatic merge from submit-queue (batch tested with PRs 50094, 48966, 49478, 50593, 49140)

apimachinery: remove pre-apigroups import path logic

Replacing #50093.

Kubernetes-commit: 9f902fef246851c11e4d17c9597853a6156688a4
2017-08-29 13:16:11 +00:00
Kubernetes Publisher 521652b00c Merge pull request #49785 from FengyunPan/fix-getPortByIP
Automatic merge from submit-queue (batch tested with PRs 47724, 49984, 49785, 49803, 49618)

Fix conflict about getPortByIp

**What this PR does / why we need it**:
Currently getPortByIp() get port of instance only based on IP.
If there are two instances in diffent network and the CIDR of
their subnet are same, getPortByIp() will be conflict.
My PR gets port based on IP and Name of instance.

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

**Special notes for your reviewer**:

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

Kubernetes-commit: a7ce691311f5462cf71d79a1f9431605198803af
2017-08-29 13:16:10 +00:00
FengyunPan 31e72764d7 Update gophercloud to support list interfaces of OpenStack instance
Kubernetes-commit: ba463062ca363bc6626dff80172782a43abe033f
2017-08-29 13:15:25 +00:00
Kubernetes Publisher 3c35b1a9b8 sync: reset Godeps/Godeps.json 2017-08-29 13:15:25 +00:00
Kubernetes Publisher 9903cc5d7a Merge pull request #50407 from ixdy/gazelle-and-kazel
Automatic merge from submit-queue (batch tested with PRs 49488, 50407, 46105, 50456, 50258)

Manage BUILD files using gazelle + kazel

**What this PR does / why we need it**: uses the upstream `gazelle` tool to manage go rules in BUILD files.
This is needed to support Bazel builds on Mac OS and Bazel cross compilation in general.

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

**Special notes for your reviewer**:
It's probably easiest to review this commit-by-commit:
* bump to latest `rules_go` (for recent `cgo_library` and `gazelle` improvements)
* update `kazel` with recent compatibility fixes (https://github.com/kubernetes/repo-infra/pull/28, https://github.com/kubernetes/repo-infra/pull/27), update `hack` scripts to download/build `gazelle`, and then run both `gazelle` and `kazel`. (Additionally make `gazelle` skip things it shouldn't touch.)
* run `hack/update-bazel.sh` to autogenerate everything
* remove the old `cgo_genrule` rules - these are now part of `go_library`
* remove the `automanaged` tags from all go rules - `gazelle` doesn't use them, and it prevents an old version of `kazel/gazel` from messing with the rules
* remove the `licenses()` rules from everywhere but `third_party/` - we don't need them, and `gazelle` won't add them on new `BUILD` files it generates.

**Release note**:

```release-note
NONE
```
for review:
/assign @mikedanese @spxtr
for approval:
/assign @thockin

Kubernetes-commit: 941ad0164d44cfcf96dd6efbb491e2222a3a23d3
2017-08-29 13:15:24 +00:00
Kubernetes Publisher e4976b3176 Merge pull request #50308 from m1093782566/validate-apiserver
Automatic merge from submit-queue

validate kube-apiserver options

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

Create Validate() or add more checks in existing Validate() for the following files:

* vendor/k8s.io/apiextensions-apiserver/pkg/cmd/server/start.go:80

* vendor/k8s.io/kube-aggregator/pkg/cmd/server/start.go:104

* vendor/k8s.io/sample-apiserver/pkg/cmd/server/start.go:82

* cmd/kube-apiserver/app/options/validation.go:49

**Which issue this PR fixes**:

fixes #50301

**Special notes for your reviewer**:

This PR follows #50135

**Release note**:

```release-note
NONE
```

Kubernetes-commit: 984f1af5c55b55f1cbbefbe7afd8f3731f06dcd2
2017-08-29 13:15:23 +00:00
Kubernetes Publisher a28089cff0 Merge pull request #50135 from m1093782566/fed-apiserver-validation
Automatic merge from submit-queue

add some checks for fedration-apiserver options

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

I find there is a TODO, see https://github.com/kubernetes/kubernetes/blob/master/federation/cmd/federation-apiserver/app/options/validation.go#L30

This PR add some checks for fedration-apiserver options

@sttts

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

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```

Kubernetes-commit: d40bfff29744de2b42d47627fe664a17cac04298
2017-08-29 13:15:23 +00:00
Kubernetes Publisher 7e2b09280d Merge pull request #50328 from shiywang/selflink
Automatic merge from submit-queue (batch tested with PRs 50300, 50328, 50368, 50370, 50372)

Add unit tests for GenerateLink

Fixes https://github.com/kubernetes/kubernetes/issues/48321
cc @lavalamp

```release-note
NONE
```

Kubernetes-commit: 9466dbb4ab374652469db5fee6f7b365a0575e01
2017-08-29 13:15:22 +00:00
Kubernetes Publisher f0085e9ad7 Merge pull request #50254 from liggitt/revert-disk-cache
Automatic merge from submit-queue (batch tested with PRs 50254, 50174, 50179)

Revert "Merge pull request #47353 from apelisse/http-cache"

Some issues were discovered with the caching merged in #47353:
* uses a disk-based cache that is not safe between processes (does not use atomic fs operations)
* writes get/list responses to disk that should not be cached (like `kubectl get secrets`)
* is vulnerable to partially written cache responses being used as responses to future requests
* breaks uses of the client transport that make use of websockets
* defaults to enabling the cache for any client builder using RecommendedConfigOverrideFlags or DefaultClientConfig which affects more components than just kubectl

This reverts commit fc89743dca6b563063b74728c3b28100cf674d9d, reversing changes made to 29ab38e898988c36e2de34f77fa33be556eb21bd.

Kubernetes-commit: 187e6ab0bc35f696d8f5f574fab9aa457f253d34
2017-08-29 13:15:22 +00:00
Jordan Liggitt 4661d61624 Revert "Merge pull request #47353 from apelisse/http-cache"
This reverts commit fc89743dca6b563063b74728c3b28100cf674d9d, reversing
changes made to 29ab38e898988c36e2de34f77fa33be556eb21bd.

Kubernetes-commit: 4ee72eb300423772020dd1cf208159058ba7dab5
2017-08-29 13:14:39 +00:00
Kubernetes Publisher 1cbe8b85c9 sync: reset Godeps/Godeps.json 2017-08-29 13:14:39 +00:00
Kubernetes Publisher 0e4f9d22d1 Merge pull request #50159 from liggitt/includeObject
Automatic merge from submit-queue

Fix includeObject parameter parsing

Fixes #50149

Kubernetes-commit: c75d3028dda35e25603aad580326385b8d141f93
2017-08-29 13:14:38 +00:00
Kubernetes Publisher 7dd46577b6 Merge pull request #49678 from smarterclayton/429_metric
Automatic merge from submit-queue

Timeout and Max-in-flight don't report non-resource URLs correctly.

Unify error reporting for 429 and 504 to be correct for timeout and max in flight and eviction. Add better messages to eviction (removing a todo). Return the correct body content for timeouts (reason and code should be correct).

This potentially increases cardinality of 429, but because non-api urls may be under the max-inflight budget we need to report them somewhere (if something breaks and starts fetching API versions endlessly).

```release-note
The 504 timeout error was returning a JSON error body that indicated it was a 500.  The body contents now correctly report a 500 error.
```

Kubernetes-commit: 8d6bbaa85f96f14ac9c9722ed1677e1052c974ba
2017-08-29 13:14:37 +00:00
Kubernetes Publisher 265b663b44 Merge pull request #47353 from apelisse/http-cache
Automatic merge from submit-queue

go-client: Use httpcache client for all requests, even though only openapi returns ETags for caching

**What this PR does / why we need it**: Use HTTP ETag for caching Swagger spec download

This also adds a new command-line flag "cachedir" to specify where the cache should keep its file. It defaults to `$HOME/.kube/http-cache`.

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

**Special notes for your reviewer**:
Because this adds a bunch of dependencies, and removes a couple of files, I do recommend reading each commit individually.

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

Kubernetes-commit: fc89743dca6b563063b74728c3b28100cf674d9d
2017-08-29 13:14:36 +00:00
Antoine Pelisse a3596c5884 c-go: Add dependencies for http-cache
Kubernetes-commit: e77d298f83114318fabce9f36546c9f6a7c24938
2017-08-29 13:13:52 +00:00
Kubernetes Publisher 02bf6f13d2 sync: reset Godeps/Godeps.json 2017-08-29 13:13:52 +00:00
Kubernetes Publisher d3f9123b11 Merge pull request #48969 from ixdy/update-kazel
Automatic merge from submit-queue (batch tested with PRs 50103, 49677, 49449, 43586, 48969)

Run kazel on the entire tree

**What this PR does / why we need it**: part of #47558: auto-generate `BUILD` files on the entire tree, since this is what `gazelle` does, and it'll make subsequent reviews easier if less is changing.

**Release note**:

```release-note
NONE
```
/assign
/release-note-none

Kubernetes-commit: d15baf69e10f3eddd59da2f6972a723a08e7dac7
2017-08-29 13:13:51 +00:00
Kubernetes Publisher 2c66dfcbee Merge pull request #49195 from huangjiuyuan/fix-typo
Automatic merge from submit-queue

fix typo in staging/src/k8s.io/apiserver/pkg/server/config.go

**What this PR does / why we need it**: Fix a typo `It's members are sorted roughly in order of importance for composers.` in `staging/src/k8s.io/apiserver/pkg/server/config.go`.

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

**Special notes for your reviewer**:

**Release note**:

`NONE`

Kubernetes-commit: 2bd0b3dd2616e5c4a6ef79d08dfb8bc8f5959ced
2017-08-29 13:13:50 +00:00
Kubernetes Publisher 06ea0476f0 Merge pull request #49300 from tklauser/syscall-to-x-sys-unix
Automatic merge from submit-queue

Switch from package syscall to golang.org/x/sys/unix

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

The syscall package is locked down and the comment in https://github.com/golang/go/blob/master/src/syscall/syscall.go#L21-L24 advises to switch code to use the corresponding package from golang.org/x/sys. This PR does so and replaces usage of package syscall with package golang.org/x/sys/unix where applicable. This will also allow to get updates and fixes
without having to use a new go version.

In order to get the latest functionality, golang.org/x/sys/ is re-vendored. This also allows to use Eventfd() from this package instead of calling the eventfd() C function.

**Special notes for your reviewer**:

This follows previous works in other Go projects, see e.g. moby/moby#33399, cilium/cilium#588

**Release note**:

```release-note
NONE
```

Kubernetes-commit: 5d24a2c19923d6da46110b827619f4b21cf689ac
2017-08-29 13:13:50 +00:00
Kubernetes Publisher fa9e59055b Merge pull request #49302 from sttts/sttts-missing-codecs
Automatic merge from submit-queue

Add missing ugorji codecs for auth/v1, settings/v1alphav1 and storage/v1

Kubernetes-commit: f8affc7dcc9e227b5d883d2322105be779d22125
2017-08-29 13:13:07 +00:00
Tobias Klauser 98556d38c2 bump(golang.org/x/sys): 7a4fde3fda8ef580a89dbae8138c26041be14299
Kubernetes-commit: 1fd18181ab38a6d65cda26f53b7e4d95f6009878
2017-08-29 13:13:07 +00:00
Kubernetes Publisher 29ed962d0a sync: reset Godeps/Godeps.json 2017-08-29 13:13:07 +00:00
Kubernetes Publisher a1940c88e1 Merge pull request #49782 from supereagle/update-generated-deepcopy
Automatic merge from submit-queue (batch tested with PRs 50029, 48517, 49739, 49866, 49782)

Update generated deepcopy code

**What this PR does / why we need it**:
In generated deepcopy code, the method names in comments do not match the real method names.

**Which issue this PR fixes**: fixes #49755

**Special notes for your reviewer**:
/assign @sttts @caesarxuchao

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

Kubernetes-commit: 84e0326eb1f108f0d7aa2e9e48fb0c4a8edb4bd5
2017-08-29 13:13:05 +00:00
Kubernetes Publisher 713755562e Merge pull request #48861 from mbohlool/openapi_aggr
Automatic merge from submit-queue (batch tested with PRs 49992, 48861, 49267, 49356, 49886)

Reintegrate aggregation support for OpenAPI

Reintegrating changes of #46734

Changes summary:

- Extracted all OpenAPI specs to new repo `kube-openapi`
- Make OpenAPI spec aggregator to copy and rename any non-requal model (even with documentation change only).
- Load specs when adding APIServices and retry on failure until successful spec retrieval or a 404.
- Assumes all Specs except aggregator's Spec are static
- A re-register of any APIService will result in updating the spec for that service (Suggestion for TPR: they should be registered to aggregator API Server, Open for discussion if any more changes needed for another PR.)

fixes #48548

Kubernetes-commit: 9067d359511890b893794c2e0a93bff88ed7d697
2017-08-29 13:13:04 +00:00
Kubernetes Publisher 8fcacc09b4 Merge pull request #49858 from smarterclayton/openapi_perf
Automatic merge from submit-queue (batch tested with PRs 49871, 49422, 49092, 49858, 48999)

bump(github.com/googleapis/gnostic):0c5108395e2de

Pick up performance improvements to OpenAPI serialization.

Fixes #49776

Kubernetes-commit: ba118b408b50da2dd7c76e7f3e5dfa595781bf47
2017-08-29 13:13:03 +00:00
Clayton Coleman 0d1444d543 bump(github.com/googleapis/gnostic):0c5108395e2de
Pick up performance improvements to OpenAPI serialization.

Kubernetes-commit: 7a458730d7d3eca8ee66ee6ce299aa978f2f09a4
2017-08-29 13:12:15 +00:00
Kubernetes Publisher d48bd1314b sync: reset Godeps/Godeps.json 2017-08-29 13:12:14 +00:00
Kubernetes Publisher 149fc22286 sync: resync vendor folder 2017-08-01 23:57:28 +00:00
Kubernetes Publisher 5d751e6c43 sync: resync vendor folder 2017-07-29 13:56:00 +00:00
Kubernetes Publisher 4269e55801 sync: resync vendor folder 2017-07-28 13:56:57 +00:00
Timothy St. Clair bd580877ac Updates godep for etcd-client to 3.1.10.
Kubernetes-commit: a8b2146ef3d024137244a4d7197e344001d7fb58
2017-07-28 13:56:11 +00:00
Di Xu bb78a51058 update json-patch to fix nil value issue when creating mergepatch
Kubernetes-commit: 8447cee0e0de612703a2fe3c5de0a2345e9bd0c5
2017-07-28 13:56:11 +00:00
Taylor Thomas 69baf544e3 Updating staging Godeps
Kubernetes-commit: 278789e639d50e40b4e3b8a3b98c9fcaec6a89c5
2017-07-28 13:56:11 +00:00
Kubernetes Publisher b6f695c703 sync: reset Godeps.json 2017-07-28 13:56:10 +00:00
Kubernetes Publisher d7bba18199 sync: resync vendor folder 2017-07-19 03:49:47 +00:00
Mikhail Mazurskiy 84487fd2f4 github.com/stretchr/testify - main desired update. Old version has bugs.
github.com/davecgh/go-spew/spew is set to the newest version, a bit
newer than required by testify. Updated from version 6 Nov 2015 to
27 Jun 2017.

github.com/stretchr/objx is not updated - testify uses version
from 27 May 2014 which is older than 28 Sep 2015 used now (latest
actually). In practice there is only a tiny difference - one method was
removed in new version.

Kubernetes-commit: de29d11bfe98fdd0dccd644b55bbe9759e89038d
2017-07-19 03:49:08 +00:00
Kubernetes Publisher e952e322b7 sync: reset Godeps.json 2017-07-19 03:49:08 +00:00
Kubernetes Publisher 7eb7a42b3f sync: resync vendor folder 2017-07-16 04:09:24 +00:00
Kubernetes Publisher 087d1a2efe sync: resync vendor folder 2017-07-06 23:56:55 +00:00
Kubernetes Publisher e30df5e70e sync: resync vendor folder 2017-07-06 00:00:01 +00:00
Kubernetes Publisher 9280d6bd4f sync: resync vendor folder 2017-07-04 08:40:17 +00:00
Kubernetes Publisher 3c5a3c8a9a sync: resync vendor folder 2017-07-01 08:40:15 +00:00
Antoine Pelisse d57ea42cc0 Add NYTimes/gziphandler dependency
Kubernetes-commit: f617df7d6a63692ae8e0b2863f3b44f6ea02d355
2017-07-01 08:39:43 +00:00
Antoine Pelisse cd54e5008c openapi: Fetch protobuf rather than Json
This is much faster.

Kubernetes-commit: 224dba9a136e3e4014d88b3c2546418066bac026
2017-07-01 08:39:43 +00:00
Kubernetes Publisher e110091e0a sync: reset Godeps.json 2017-07-01 08:39:42 +00:00
Kubernetes Publisher fb6bc6c4e7 sync: resync vendor folder 2017-06-30 08:45:31 +00:00
Kubernetes Publisher 83e28913be sync: resync vendor folder 2017-06-30 00:11:26 +00:00
Kubernetes Publisher d9c265d166 sync: resync vendor folder 2017-06-29 00:11:26 +00:00