Commit Graph

105 Commits

Author SHA1 Message Date
deads2k
ec397c4374 convert default predicates to use the default 2017-08-07 09:05:17 -04:00
Shiyang Wang
2eda19da7b Fix NotFound errors do not line up with API endpoint's group version 2017-08-07 16:30:40 +08:00
Kubernetes Submit Queue
f26b2956fb Merge pull request #48418 from xiangpengzhao/refactor-create-svc
Automatic merge from submit-queue (batch tested with PRs 49409, 49352, 49266, 48418)

Use helper to init ClusterIP and NodePort in Create of service

**What this PR does / why we need it**:
Make service `Create` more readable and testable.

- use `initClusterIP` introduced in #46197 to init ClusterIP allocation in service `Create`
- add a new helper `initNodePort` to init NodePort allocation in service `Create`
- TBD: add test case for `initNodePort`. This will cover the NodePort allocation process in `Create`. If this PR makes sense, I will write a test case later.

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #35354 (not directly. #35354 was fixed by #46197. The idea of this PR is from https://github.com/kubernetes/kubernetes/pull/46197#discussion_r120910077)

**Special notes for your reviewer**:
/cc @thockin @freehan 

**Release note**:

```release-note
NONE
```
2017-07-22 02:05:21 -07:00
Kubernetes Submit Queue
45432de47b Merge pull request #49128 from deads2k/server-29-mising-shortname
Automatic merge from submit-queue (batch tested with PRs 49055, 49128, 49132, 49134, 49110)

add svc and netpol to discovery

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

one shortname was missing entirely, the other was on a storage not actually used as storage.

@ncdc
2017-07-18 21:54:20 -07:00
deads2k
8232778ffe add svc and netpol to discovery 2017-07-18 13:16:41 -04:00
xiangpengzhao
d765f91c1d Fix health check node port test flake 2017-07-18 19:05:40 +08:00
Clayton Coleman
c73622108c
generated: bazel / godeps 2017-07-09 15:23:34 -04:00
Clayton Coleman
edc12aafe2
Unify generic proxy code in apimachinery
Make the utility package truly generic, consolidate all generic proxy in
apimachinery.
2017-07-07 16:26:29 -04:00
xiangpengzhao
472e10faf9 Fix ClusterIP leak flake and potential NodePort leak 2017-07-07 13:02:01 +08:00
xiangpengzhao
895da2cd49 Remove shouldAssignNodePorts logic in initNodePort; add test cases. 2017-07-07 09:57:11 +08:00
xiangpengzhao
dc7fb0c9e5
Use helper to init ClusterIP and NodePort in Create of service 2017-07-03 16:35:09 +08:00
xiangpengzhao
a58232ab41 Add unit test case for initClusterIP and updateNodePort 2017-06-28 09:35:12 +08:00
xiangpengzhao
4e9abca6d0 Allocate clusterIP when change service type from ExternalName to ClusterIP 2017-06-27 12:30:22 +08:00
Fabiano Franz
058f9b4f32 Add group alias names to discovery in registry 2017-06-05 20:18:12 -03:00
Tim Hockin
be987b015c Merge pull request #46716 from thockin/proxy-comments
Kube-proxy cleanups
2017-06-03 15:57:17 -07:00
Clayton Coleman
2568a92119
Grow signature for predicate attributes to include init status 2017-06-02 22:09:04 -04:00
Clayton Coleman
331eea67d8
Allow initialization of resources
Add support for creating resources that are not immediately visible to
naive clients, but must first be initialized by one or more privileged
cluster agents. These controllers can mark the object as initialized,
allowing others to see them.

Permission to override initialization defaults or modify an initializing
object is limited per resource to a virtual subresource "RESOURCE/initialize"
via RBAC.

Initialization is currently alpha.
2017-06-02 22:09:03 -04:00
Tim Hockin
fc34a9d6ba 'Global' -> 'Cluster' for traffic policy 2017-06-01 16:17:38 -07:00
Zihong Zheng
f0739a5638 Randomize test nodePort to prevent collision 2017-05-18 15:29:22 -07:00
Zihong Zheng
a28a22df11 Move defaulting logic for ExternalTrafficPolicy into defaults.go 2017-05-17 12:47:01 -07:00
Zihong Zheng
c0920f75cf Move API annotations into annotation_key_constants and remove api/annotations package 2017-05-16 21:55:23 -07:00
Zihong Zheng
12277a0ad4 Update ESIPP validation and service registry unit tests 2017-05-12 10:59:00 -07:00
Zihong Zheng
79ca71708a Adjust ESIPP validation and service registry codes 2017-05-12 10:58:59 -07:00
Jordan Liggitt
3f4ded12be
Add PATCH to supported list of proxy subresource verbs 2017-04-27 10:38:10 -04:00
Monis Khan
ed35deb69d
Default ObjectNameFunc for all REST Stores
All Stores in Kubernetes follow the same logic for determining the name
of an object.  This change makes it so that CompleteWithOptions defaults
the ObjectNameFunc if it is not specified.  Thus a user does not need to
remember to use ObjectMeta.Name.  Using the wrong field as the name can
lead to an object which has a name that bypasses normal object name
validation.

Signed-off-by: Monis Khan <mkhan@redhat.com>
2017-04-21 15:47:25 -04:00
Zihong Zheng
ae93b0da15 Refine NeedsHealthCheck logic 2017-04-17 14:26:02 -07:00
Mike Danese
a05c3c0efd autogenerated 2017-04-14 10:40:57 -07:00
Chao Xu
08aa712a6c move helpers.go to helper 2017-04-11 15:49:11 -07:00
deads2k
04460c8750 remove objectmetafor 2017-04-10 15:13:35 -04:00
Kubernetes Submit Queue
879f8e0c9c Merge pull request #42182 from spxtr/fatalunit
Automatic merge from submit-queue

Change an Errorf to a Fatalf to prevent a panic.

In #37982 we see that if this error is hit then we will panic on the next line. Lets use `Fatalf` where appropriate :)

This does *not* fix the flake, since that's caused by the test assuming that a particular port is free.
2017-04-04 12:14:21 -07:00
Kubernetes Submit Queue
223ac9f8b0 Merge pull request #43260 from thockin/nodeport-allocation-rand-seed
Automatic merge from submit-queue (batch tested with PRs 42379, 42668, 42876, 41473, 43260)

Don't use global rand for nodeport and IP allocs

Seed it at construction.
2017-03-30 23:36:30 -07:00
Tim Hockin
348f7a7036 Don't use global rand for nodeport and IP allocs
Seed it at contruction.
2017-03-16 17:25:07 -07:00
Tim Hockin
cb95c479cb Fix polarity of a test in NodePort allocation
The result of this was that an update to a Service would release the
NodePort temporarily (the repair loop would fix it in a minute).  During
that window, another Service could get allocated that Port.
2017-03-16 17:19:26 -07:00
spxtr
824f466f17 Change an Errorf to a Fatalf to prevent a panic. 2017-02-27 10:50:03 -08:00
nikhiljindal
1d32897eed Updating the registry to return whether the resource was immediately deleted 2017-02-21 11:00:35 -08:00
p0lyn0mial
b2cce0ac8e added short names for resources which are exposed during discovery 2017-02-06 23:35:07 +01:00
Dr. Stefan Schimanski
6af3210d6f Update generated files 2017-02-03 08:15:46 +01:00
Dr. Stefan Schimanski
536460e1d9 Mechanical fixup imports: pkg/genericapiserver 2017-02-03 08:15:45 +01:00
Dr. Stefan Schimanski
80b96b441b Mechanical import fixup: pkg/storage 2017-02-03 07:33:43 +01:00
Dr. Stefan Schimanski
de2eee391a Update bazel 2017-02-02 15:19:04 +01:00
Dr. Stefan Schimanski
b8142896a7 pkg/genericapiserver: cut off pkg/registry/cachesize dependency 2017-02-02 15:19:03 +01:00
Dr. Stefan Schimanski
871fc426b3 pkg/storage: move errors here from pkg/api/errors/storage 2017-02-02 15:17:34 +01:00
Dr. Stefan Schimanski
d6adb51e6c pkg/api: move HasObjectMetaSystemFieldValues into apimachinery 2017-02-01 13:37:41 +01:00
Kubernetes Submit Queue
0469fc6fb6 Merge pull request #40742 from deads2k/generic-34-storage
Automatic merge from submit-queue (batch tested with PRs 40638, 40742, 40710, 40718, 40763)

move pkg/storage to apiserver

Mechanical move of `pkg/storage` (not sub packages) to `k8s.io/apiserver`.

@sttts
2017-01-31 20:40:43 -08:00
Kubernetes Submit Queue
8fe7a2decb Merge pull request #40342 from louyihua/remove_warning
Automatic merge from submit-queue (batch tested with PRs 40111, 40368, 40342, 40274, 39443)

Eliminate "Unknown service type: ExternalName"

When creating an ExternalName service, rest.go still generate the warning message "Unknown service type: ExternalName". This should be eliminated as this type of service is supported now.
2017-01-31 19:18:41 -08:00
deads2k
1ef5d26079 move pkg/storage to apiserver 2017-01-31 19:07:33 -05:00
deads2k
c9a008dff3 move util/intstr to apimachinery 2017-01-30 12:46:59 -05:00
deads2k
9fb37f3bba remove storage dependency on api 2017-01-27 14:02:28 -05:00
deads2k
aea12038b4 move storage/storagebackend to apiserver 2017-01-27 08:49:55 -05:00
Dr. Stefan Schimanski
2b8e938128 Update generated files 2017-01-24 20:56:03 +01:00