Commit Graph

11980 Commits (22dfaef9f02e3f7cbb265a968555aed4fb44b50f)

Author SHA1 Message Date
Minhan Xia 04b80f7fb8 rename Status interface to GetPodNetworkStatus 2016-05-04 13:46:31 -07:00
Minhan Xia 265fdd9344 add NetworkStatus in NetworkPlugin interface for kubelet to consume 2016-05-04 13:46:31 -07:00
Sami Wagiaalla d1aacfc059 Move getCloudProvider retries to getCloudProvider() 2016-05-04 16:43:38 -04:00
k8s-merge-robot 93e3df8e55 Merge pull request #24789 from wojtek-t/use_proper_codec_in_client
Automatic merge from submit-queue

Use proper codec in client
2016-05-04 11:00:04 -07:00
Jan Safranek 42d940735b Make threadSafeMap.ListIndexFuncValues thread safe.
Surprisingly, this method does not lock and I get data race reports
in my persistent volume unit tests (which use this map).
2016-05-04 18:18:00 +02:00
Dan Williams aad6535a00 kubenet: fix up CNI bridge TX queue length if needed
CNI's bridge plugin mis-handles the TxQLen when creating the bridge,
leading to a zero-length TX queue.  This doesn't typically cause
problems (since virtual interfaces don't have hard queue limits)
but when adding traffic shaping, some qdiscs pull their packet
limits from the TX queue length, leading to a packet limit of 0
in some cases.  Until we can depend on a new enough version of
CNI, fix up the TX queue length internally.
2016-05-04 10:14:40 -05:00
Marcin Wielgus 8e90cded97 Update Heapster api types location in Godeps 2016-05-04 16:27:12 +02:00
k8s-merge-robot 1642083e60 Merge pull request #24645 from jlowdermilk/rolling-update
Automatic merge from submit-queue

kubectl rolling-update support for same image

Fixes #23497.

Enables `kubectl rolling-update --image` to the same image, adding a `--image-pull-policy` flag to remove ambiguity. This allows rolling-update to behave as an "update and/or restart" (https://github.com/kubernetes/kubernetes/issues/23497#issuecomment-212349730), or as a forced update when the same tag can mean multiple versions (e.g. `:latest`). cc @janetkuo @nikhiljindal
2016-05-04 07:24:22 -07:00
Sami Wagiaalla 71e7dba845 Abstract node side functionality of attachable plugins
- Expand Attacher/Detacher interfaces to break up work more
  explicitly.
- Add arguments to all functions to avoid having implementers store
  the data needed for operations.
- Expand unit tests to check that Attach, Detach, WaitForAttach,
  WaitForDetach, MountDevice, and UnmountDevice get call where
  appropriet.
2016-05-04 10:18:39 -04:00
Wojciech Tyczynski 11849e232e Fix bug in json framer. 2016-05-04 15:02:07 +02:00
Jan Safranek f4abfb2a0c Make fake event recorder thread safe.
The test recorder should be thread safe in case it's used in multiple
goroutines. This does not serve to ensure any order of recorded events,
only to prevent golang race detector to crash when two events are emitted by
concurrent goroutines.
2016-05-04 14:20:13 +02:00
k8s-merge-robot bc010d76cc Merge pull request #24751 from krousey/meta_unstructured
Automatic merge from submit-queue

Redo Unstructured to have accessor methods

Add accessor methods that implement pkg/api/unversioned.ObjectKind,
pkg/api/meta.Object, pkg/api/meta.Type and pkg/api/meta.List.

Removed the convenience fields since writing to them was not reflected
in serialized JSON.
2016-05-04 04:22:34 -07:00
k8s-merge-robot 72c7dd4b95 Merge pull request #25068 from hongchaodeng/fix
Automatic merge from submit-queue

etcd3/store: userUpdate error should be returned

Minor fix.
The userUpdate error should be returned.
2016-05-04 03:07:01 -07:00
Wojciech Tyczynski 303742ce12 Merge pull request #24723 from smarterclayton/strip_noop_imports
Protobuf generation should strip side-effect imports
2016-05-04 11:16:45 +02:00
Wojciech Tyczynski 3aadafd411 Use NegotiatedSerializer in client 2016-05-04 10:57:36 +02:00
Marcin Wielgus 60f1339138 Small refactoring around drain - move drain logic to separate function. 2016-05-04 10:43:20 +02:00
Wojciech Tyczynski b4c83022e3 Add NegotiatedSerializer to config 2016-05-04 10:02:58 +02:00
Paul Morie 7521503ab9 Reduce kubelet LOC: extract getters 2016-05-04 02:25:22 -04:00
Matt Freeman 89e5e81bea Handle possible error in client reflector run loops 2016-05-04 05:01:54 +00:00
AdoHe 036ac359d1 update kubectl apply help info 2016-05-03 22:50:24 -04:00
zhouhaibing089 67747ca08f allow equality to avoid flaky on clock 2016-05-04 09:11:22 +08:00
AdoHe ba69f0f367 mark container-port flag as deprecated 2016-05-03 20:36:42 -04:00
Daniel Smith d1de30cd6c remove inappropriate time.Sleep 2016-05-03 16:37:28 -07:00
saadali 71302d1163 Add data structure for storing attach detach controller state. 2016-05-03 14:11:10 -07:00
Kris 28132be07e Redo Unstructured to have accessor methods
Add accessor methods that implement pkg/api/unversioned.ObjectKind,
pkg/api/meta.Object, pkg/api/meta.Type and pkg/api/meta.List.

Removed the convenience fields since writing to them was not reflected
in serialized JSON.
2016-05-03 14:07:28 -07:00
nikhiljindal 16c0e0a21c Deleting duplicate code from federated-apiserver 2016-05-03 14:04:09 -07:00
Janet Kuo f3b1aaeca6 Fix incorrect comments in IsPodAvailable 2016-05-03 13:05:02 -07:00
k8s-merge-robot c66250dd0d Merge pull request #24548 from pwittrock/kubectl
Automatic merge from submit-queue

Delete unused helpers
2016-05-03 11:26:25 -07:00
k8s-merge-robot 946a311e7b Merge pull request #25014 from smarterclayton/broken_framing_growth
Automatic merge from submit-queue

Frame decoder was checking cap(), not len()

Resulted in bytes being missing from the streaming decoder. Update both
parts.

Required for #24789

@wojtek-t or @lavalamp while he's OOO
2016-05-03 11:26:15 -07:00
Andy Goldstein 3a87bfb6f7 PLEG: reinspect pods that failed prior inspections
Fix the following sequence of events:

1. relist call 1 successfully inspects a pod (just has infra container)
1. relist call 2 gets an error inspecting the same pod (has infra container and a transient
container that failed to create) and doesn't update the old/new pod records
1. relist calls 3+ don't inspect the pod any more (just has infra container so it doesn't look like
anything changed)

This change adds a new list that keeps track of pods that failed inspection and retries them the
next time relist is called. Without this change, a pod in this state would never be inspected again,
its entry in the status cache would never be updated, and the pod worker would never call syncPod
again because the most recent entry in the status cache has an error associated with it. Without
this change, pods in this state would be stuck Terminating forever, unless the user issued a
deletion with a grace period value of 0.
2016-05-03 11:06:35 -04:00
Hongchao Deng 84c07b0bbf etcd3/store: userUpdate error should be returned 2016-05-03 14:42:29 +08:00
Gao Zheng c75cb94be6 Squashed commit of the following:
commit 7bf1a05f61b78196c8d272e0d55980ba2254e81d
Author: gaozheng <gaozheng0123@163.com>
Date:   Thu Apr 28 01:23:42 2016 +0000

    fix gofmt

commit 54f6fa6ca76ee0fc5c4f8609fb2f875111ce2141
Author: Gao Zheng <gaozheng0123@163.com>
Date:   Sat Apr 23 13:09:41 2016 +0000

    reset session affinity if endpoint is unconnected
2016-05-03 01:36:32 +00:00
Random-Liu 4cca5b2290 Use fake clock in TestGetPodsToSync to fix flake. 2016-05-02 16:05:36 -07:00
Clayton Coleman 99430cf5de
Strip side-effect imports from generated protobuf 2016-05-02 18:12:20 -04:00
Yu-Ju Hong 43fc67a5f6 kubelet: do not force update the runtime cache
Pod workers don't rely on the old runtime cache to sync pods anymore. There is
no need to force update the cache on every container event.
2016-05-02 15:10:00 -07:00
k8s-merge-robot 879c1807c8 Merge pull request #24821 from freehan/kubenetmutex
Automatic merge from submit-queue

add mutex for kubenet

I saw a bunch of weird cases in kubenet suite. For instance, SetUpPod return successfully, but right after that, kubelet cannot retrieve podIP from podCIDR map.


cc: @dcbw @thockin 

ref: #24211
2016-05-02 13:16:23 -07:00
saadali 53bb527e35 Introduce a data structure for managing go routines by unique name. 2016-05-02 12:02:34 -07:00
k8s-merge-robot 928990730e Merge pull request #24457 from leokhoa/master
Automatic merge from submit-queue

AWS: Add support for ap-northeast-2 region (Seoul)

This PR does:
- Support AWS Seoul region: ap-northeast-2. 
Currently, I can not setup Kubernetes on AWS Seoul.  
Error Messages: 

> 
> ip-10-0-0-50 core # docker logs 0697db
> I0419 07:57:44.569174       1 aws.go:466] Zone not specified in configuration file; querying AWS metadata service
> F0419 07:57:44.570380       1 controllermanager.go:279] Cloud provider could not be initialized: could not init cloud provider "aws": not a valid AWS zone (unknown region): ap-northeast-2a
2016-05-02 09:46:47 -07:00
k8s-merge-robot f500194d92 Merge pull request #23673 from metral/multiple-resources
Automatic merge from submit-queue

allow kubectl subcmds to process multiple resources

~~autoscale, expose & patch~~ Many kubectl subcommands were limited to processing one resource at a time.

This PR allows those subcommands to process multiple resources.

This PR is in reference to https://github.com/kubernetes/kubernetes/pull/23116#issuecomment-202360784 by @deads2k
2016-05-02 07:09:44 -07:00
Michail Kargakis a25088fe15 kubectl: more sophisticated pod selection for logs and attach 2016-05-02 15:56:36 +02:00
k8s-merge-robot c66b2b4e05 Merge pull request #23865 from rhcarvalho/unify-signal-handling
Automatic merge from submit-queue

Unify termination signal handling across platforms

The signals are used to ensure proper execution of cleaning up actions to restore a terminal in:
- [pkg/kubectl/cmd/attach.go#L163-L226](b8d000853e/pkg/kubectl/cmd/attach.go (L163-L226))
- [pkg/kubectl/cmd/util/editor/editor.go#L112-L137](b8d000853e/pkg/kubectl/cmd/util/editor/editor.go (L112-L137))

All supported platforms can handle the same set of signals we're interested in, thus we don't need build contraints to use a set of signals on Linux, while restricting ourselves to only SIGINT on Darwin and Windows.

According to the documentation of os/signal, similar to SIGINT and SIGTERM, SIGHUP causes the program to exit, therefore add it to the list of handled signals.

The fist commit is part of #23643.
2016-05-02 04:09:25 -07:00
Michail Kargakis dbc1e356d3 kubectl: remove dead factory code 2016-05-02 11:03:44 +02:00
Mike Metral 999c8e211e allow kubectl subcmds to process multiple resources
- use resource.Visit() to recursively process resources, as well as, aggregate
errors where possible
2016-05-01 20:27:37 -07:00
Xiangpeng Zhao d27127aaf8 Rename a func in order to be difference with variable
Rename `defaultSecurityOpt` to `getDefaultSecurityOpt`
2016-05-02 03:02:49 +08:00
Clayton Coleman 84dee0d9cc
Frame decoder was checking cap(), not len()
Resulted in bytes being missing from the streaming decoder. Update both
parts.
2016-04-30 17:57:17 -04:00
k8s-merge-robot b930d58fcb Merge pull request #24994 from pmorie/kubectl-configmap
Automatic merge from submit-queue

Fix `kubectl create configmap` help

Resurrection of #23290

cc @bgrant0607 @janetkuo @ncdc
2016-04-29 23:09:42 -07:00
Jordan Liggitt e41d504739 Move ThirdPartyResource to root scoped object 2016-04-30 01:06:07 -04:00
Timothy Chen d218f55dd5 Add docs for podautoscaler package 2016-04-29 18:39:48 -07:00
Clayton Coleman fdb110c859
Fix the rest of the code 2016-04-29 17:12:10 -04:00
Clayton Coleman 8d0187add2
Generation changes 2016-04-29 17:12:09 -04:00
Clayton Coleman cf133ee03a
Convert remaining int types to fixed
Having internal and external integer types being different hides
potential conversion problems. Propagate that out further (which will
also allow us to better optimize conversion).
2016-04-29 17:12:04 -04:00
Sami Wagiaalla e1e7da2712 Add GIDs specified in a PV's annotations to pod's supplemental groups 2016-04-29 16:44:56 -04:00
Random-Liu 7796b619fd Cleanup the code with new engine-api 2016-04-29 13:34:38 -07:00
Random-Liu 3876972d3f Clean up go-dockerclient reference. 2016-04-29 13:32:19 -07:00
Andy Goldstein 8858d20044 Fix `kubectl create configmap` help
Remove "generic" from the help text, as that was an inadvertent carry-over from `kubectl create
secret generic`.
2016-04-29 16:31:24 -04:00
k8s-merge-robot 2b7021add0 Merge pull request #17030 from csrwng/pf_cmd_streams
Automatic merge from submit-queue

Port-forward: use out and error streams instead of glog

Switches use of glog with command out and error streams
2016-04-29 09:27:47 -07:00
k8s-merge-robot 11298d02e0 Merge pull request #24455 from hongchaodeng/fl
Automatic merge from submit-queue

Provide flags to use etcd3 backed storage

ref: #24405

What's in this PR?
- Add a new flag "storage-backend" to choose "etcd2" or "etcd3". By default (i.e. empty), it's "etcd2".
- Take out etcd config code into a standalone package and let it create etcd2 or etcd3 storage backend given user input.
2016-04-29 08:49:04 -07:00
k8s-merge-robot c0fca43260 Merge pull request #24915 from wojtek-t/read_closer_in_streaming_decoder
Automatic merge from submit-queue

Support Close() in streaming decoder

[This would be useful for changes in clients to support protobufs.]
2016-04-29 07:21:23 -07:00
derekwaynecarr 033ae3e37e Define interfaces for kubelet observing admission, sync loop, sync pod 2016-04-29 10:16:03 -04:00
k8s-merge-robot 46a6cae14e Merge pull request #24907 from smarterclayton/default_inliners
Automatic merge from submit-queue

Make all defaulters public

Will allow for generating direct accessors in conversion code instead of using reflection.

@wojtek-t
2016-04-29 06:36:09 -07:00
k8s-merge-robot ad67363c12 Merge pull request #24362 from ArtfulCoder/hostname-field
Automatic merge from submit-queue

Promote Pod Hostname & Subdomain to fields (were annotations)

Deprecating the podHostName, subdomain and PodHostnames annotations and created corresponding new fields for them on PodSpec and Endpoints types.

Annotation doc: #22564
Annotation code: #20688
2016-04-29 01:06:45 -07:00
k8s-merge-robot 8f9bff5b25 Merge pull request #24906 from smarterclayton/better_benchmark
Automatic merge from submit-queue

Slightly more effective conversion test (better variety)

Exercises more code paths for debugging memory allocations.
2016-04-28 23:17:57 -07:00
AdoHe 6958db9c16 fix config view output bug 2016-04-28 23:04:57 -04:00
k8s-merge-robot 492762d394 Merge pull request #24911 from pmorie/kubelet-godoc
Automatic merge from submit-queue

Add godoc for some kubelet funcs

Chipping away at that old boulder

@kubernetes/sig-node
2016-04-28 14:52:45 -07:00
Paul Morie b9f0e8c610 Add godoc for some kubelet funcs 2016-04-28 17:03:37 -04:00
Abhishek Shah 8a3ed48808 Added Hostname and Subdomain field to Pod.Spec 2016-04-28 10:56:56 -07:00
chengyli 1fb33aa2da fix cinder volume dir umount issue #24717
fix https://github.com/kubernetes/kubernetes/issues/24717
If kubelet root-dir is a symlink, the pod's cinder volume dir can't be
umounted even after pod is deleted.
This patch reads target path of symlink before comparing with entries in
proc mounts.
2016-04-29 00:50:33 +08:00
Slava Semushin e83200d322 printLabelsMultilineWithIndent: add more customizable method. 2016-04-28 18:37:41 +02:00
Slava Semushin 72b4b54f28 kubectl describe: show multiple labels/annotations on multiple lines.
When there is more than one label/annotation, it's more readable to see
them on the different lines.
2016-04-28 18:37:41 +02:00
Clayton Coleman 931f352fdf
Rename apps/v1alpha1/defaulting.go to be consistent 2016-04-28 12:20:17 -04:00
Clayton Coleman 3e36dd62c6
Move defaulter functions to public methods with a convention
Preparing to generate direct defaulter access.
2016-04-28 12:20:13 -04:00
Jordan Liggitt 1e5815872e Validate deletion timestamp doesn't change on update 2016-04-28 11:50:48 -04:00
k8s-merge-robot 7a725418af Merge pull request #24622 from derekwaynecarr/pod_qos_util
Automatic merge from submit-queue

Add utility for determining qos of a pod

@vishh - per slack chat.
2016-04-28 07:26:50 -07:00
Rodolfo Carvalho 9576f71b9a Unify termination signal handling across platforms
- All supported platforms can handle the same set of signals we're
  interested in, thus we don't need build contraints to use a set of
  signals on Linux, while restricting ourselves to only SIGINT on Darwin
  and Windows.
- According to the documentation of os/signal, similar to SIGINT and
  SIGTERM, SIGHUP causes the program to exit, therefore add it to the
  list of handled signals.

Signed-off-by: Rodolfo Carvalho <rcarvalh@redhat.com>
2016-04-28 15:35:50 +02:00
k8s-merge-robot 2347d0f047 Merge pull request #24601 from deads2k/qualify-admission-attributes
Automatic merge from submit-queue

fully qualify admission resources and kinds

Fully qualifies the `Kind` and `Resource` fields for admission attributes.  The information was getting filtered at the `RESTHandler` before.

@derekwaynecarr
2016-04-28 05:12:28 -07:00
mqliang 3bcd5b1648 fix PrepareForUpdate bug for PV and PVC 2016-04-28 19:13:02 +08:00
k8s-merge-robot 00308f7a9f Merge pull request #24598 from wojtek-t/improve_scheduler_predicates
Automatic merge from submit-queue

Store node information in NodeInfo

This is significantly improving scheduler throughput.

On 1000-node cluster:
- empty cluster: ~70pods/s
- full cluster: ~45pods/s
Drop in throughput is mostly related to priority functions, which I will be looking into next (I already have some PR #24095, but we need for more things before).

This is roughly ~40% increase.
However, we still need better understanding of predicate function, because in my opinion it should be even faster as it is now. I'm going to look into it next week.

@gmarek @hongchaodeng @xiang90
2016-04-28 02:17:59 -07:00
Michail Kargakis 29ff69fd83 kubectl: avoid panic with nil gvk
The decoder will return a nil gvk in case it errors out and getting
the version out of that gvk naturally will panic. Bail out as soon
as we can check that the error is non-nil. kubectl edit was the primary
victim.
2016-04-28 11:14:15 +02:00
k8s-merge-robot d0b887e4e0 Merge pull request #24595 from zhouhaibing089/httpserverclose
Automatic merge from submit-queue

Uncomment the code that caused by #19254

Fix https://github.com/kubernetes/kubernetes/issues/24546.

@lavalamp
2016-04-28 01:41:16 -07:00
k8s-merge-robot 04b70bc6c7 Merge pull request #24376 from resouer/fix-cache
Automatic merge from submit-queue

Do not update cache with so much effort

Fixes: #24298
1. Remove automatic update
2. Every time we check if we can get valid value from cache, if not, get the value directly from api

cc @Random-Liu
2016-04-28 01:00:33 -07:00
Wojciech Tyczynski 3175d18b14 Support Close() in streaming decoder 2016-04-28 09:46:33 +02:00
k8s-merge-robot ae5065a2c2 Merge pull request #24365 from janetkuo/remove-t-for-tty
Automatic merge from submit-queue

Add flag -t as shorthand for --tty

`-t` was deprecated in #12813 (Aug. 2015, about 6+ months ago). 

Now remove `--template`'s shorthand `-t` and create a shorthand `-t` for `--tty` in `kubectl run`. 

@kubernetes/kubectl
2016-04-28 00:23:11 -07:00
Clayton Coleman d0a7b93050 Slightly more effective conversion test (better variety) 2016-04-27 23:11:25 -04:00
k8s-merge-robot 4a0e0826e5 Merge pull request #24220 from gmarek/metrics
Automatic merge from submit-queue

Generated clients can return their RESTClients, RESTClient can return its RateLimiter

cc @lavalamp @krousey @wojtek-t @smarterclayton @timothysc 

Ref. #22421
2016-04-27 19:25:38 -07:00
Hongchao Deng c0071a1595 add flags to enable etcd3 2016-04-28 09:48:16 +08:00
k8s-merge-robot d89b6bc6e6 Merge pull request #24774 from XiaoningDing/federation-apiserver-version
Automatic merge from submit-queue

Move install of version handler to genericapiserver

This is to satisfy kbuectl verification

Please review only the last commit.

#19313 #23653
@nikhiljindal @quinton-hoole, @deepak-vij, @XiaoningDing, @alfred-huangjian @mfanjie @huangyuqi @colhom
2016-04-27 14:39:24 -07:00
gmarek 3171aac57c Generated clients can return their RESTClients, RESTClient can return its RateLimiter 2016-04-27 22:15:10 +02:00
k8s-merge-robot 4c7abddc1c Merge pull request #24567 from yifan-gu/post_start_hook
Automatic merge from submit-queue

rkt: Add post-start hook support.

This adds a poll-and-timeout procedure after the pod is
started, to make sure the post-start hooks execute when the
container is actually running.

This is a temporal workaround for implementing post-hooks,
a long term solution is to use lifecycle event to trigger
those hooks, see https://github.com/kubernetes/kubernetes/issues/23084.

Also this fixes a bug of getting container ID for a non-running
container when running pre-stop hook.


cc @sjpotter @euank @kubernetes/sig-node
2016-04-27 11:14:35 -07:00
Cesar Wong 55114efcb7 Port-forward: use out and error streams instead of glog 2016-04-27 13:26:54 -04:00
k8s-merge-robot 3a19ad7908 Merge pull request #24559 from derekwaynecarr/eviction_flags
Automatic merge from submit-queue

Add kubelet flags for eviction threshold configuration

This PR just adds the flags for kubelet eviction and the associated generated code.

I am happy to tweak text, but we can also do that later at this point in the release.

Since this causes codegen, I wanted to stage this first.

/cc @vishh @kubernetes/sig-node
2016-04-27 10:25:48 -07:00
jianhuiz fdfe42ea44 move install of version handler to genericapiserver 2016-04-27 10:21:08 -07:00
Paul Morie 11113a00d7 Clarify log messages for orphaned volume cleanup 2016-04-27 13:20:43 -04:00
k8s-merge-robot 7e430f543b Merge pull request #24545 from swagiaal/rename-cleaner-tuple
Automatic merge from submit-queue

Rename cleanerTuple to cleaner

Rename cleanerTuple to cleaner.
This is a follow up to address: https://github.com/kubernetes/kubernetes/pull/19503#discussion_r49538769

@saad-ali
2016-04-27 09:51:26 -07:00
k8s-merge-robot 28bc4b32c2 Merge pull request #24532 from rsc/master
Automatic merge from submit-queue

apiserver latency reductions

Combined effect of these two commits on the latency observed by the 1000-node kubemark benchmark:

```
name                               old ms/op  new ms/op   delta
LIST_nodes_p50                      127 ±16%    121 ± 9%   -4.58%  (p=0.000 n=29+27)
LIST_nodes_p90                      326 ±12%    266 ±12%  -18.48%  (p=0.000 n=29+27)
LIST_nodes_p99                      453 ±11%    400 ±14%  -11.79%  (p=0.000 n=29+28)
LIST_replicationcontrollers_p50    29.4 ±49%   26.2 ±54%     ~     (p=0.085 n=30+29)
LIST_replicationcontrollers_p90    83.0 ±78%   68.6 ±59%  -17.33%  (p=0.013 n=30+28)
LIST_replicationcontrollers_p99     216 ±43%    177 ±49%  -17.68%  (p=0.000 n=29+29)
DELETE_pods_p50                    24.5 ±14%   24.3 ±13%     ~     (p=0.562 n=30+29)
DELETE_pods_p90                    30.7 ± 1%   30.7 ± 1%   -0.30%  (p=0.011 n=29+29)
DELETE_pods_p99                    77.2 ±34%   54.2 ±23%  -29.76%  (p=0.000 n=30+27)
PUT_replicationcontrollers_p50     5.86 ±26%   5.94 ±32%     ~     (p=0.734 n=29+29)
PUT_replicationcontrollers_p90     15.8 ± 7%   15.5 ± 6%   -2.06%  (p=0.010 n=29+29)
PUT_replicationcontrollers_p99     57.8 ±35%   39.5 ±55%  -31.60%  (p=0.000 n=29+29)
PUT_nodes_p50                      14.9 ± 2%   14.8 ± 2%   -0.68%  (p=0.012 n=30+27)
PUT_nodes_p90                      16.5 ± 1%   16.3 ± 2%   -0.90%  (p=0.000 n=27+28)
PUT_nodes_p99                      57.9 ±47%   41.3 ±35%  -28.61%  (p=0.000 n=30+28)
POST_replicationcontrollers_p50    6.35 ±29%   6.34 ±20%     ~     (p=0.944 n=30+28)
POST_replicationcontrollers_p90    15.4 ± 5%   15.0 ± 5%   -2.18%  (p=0.001 n=29+29)
POST_replicationcontrollers_p99    52.2 ±71%   32.9 ±46%  -36.99%  (p=0.000 n=29+27)
POST_pods_p50                      8.99 ±13%   8.95 ±16%     ~     (p=0.903 n=30+29)
POST_pods_p90                      16.2 ± 4%   16.1 ± 4%     ~     (p=0.287 n=29+29)
POST_pods_p99                      30.9 ±21%   26.4 ±12%  -14.73%  (p=0.000 n=28+28)
POST_bindings_p50                  9.34 ±12%   8.92 ±15%   -4.54%  (p=0.013 n=30+28)
POST_bindings_p90                  16.6 ± 1%   16.5 ± 3%   -0.73%  (p=0.017 n=28+29)
POST_bindings_p99                  23.5 ± 9%   21.1 ± 4%  -10.09%  (p=0.000 n=27+28)
PUT_pods_p50                       10.8 ±11%   10.2 ± 5%   -5.47%  (p=0.000 n=30+27)
PUT_pods_p90                       16.1 ± 1%   16.0 ± 1%   -0.64%  (p=0.000 n=29+28)
PUT_pods_p99                       23.4 ± 9%   20.9 ± 9%  -10.93%  (p=0.000 n=28+27)
DELETE_replicationcontrollers_p50  2.42 ±16%   2.50 ±13%     ~     (p=0.054 n=29+28)
DELETE_replicationcontrollers_p90  11.5 ±12%   11.8 ±13%     ~     (p=0.141 n=30+28)
DELETE_replicationcontrollers_p99  19.5 ±21%   19.1 ±21%     ~     (p=0.397 n=29+29)
GET_nodes_p50                      0.77 ±10%   0.76 ±10%     ~     (p=0.317 n=28+28)
GET_nodes_p90                      1.20 ±16%   1.14 ±24%   -4.66%  (p=0.036 n=28+29)
GET_nodes_p99                      11.4 ±48%    7.5 ±46%  -34.28%  (p=0.000 n=28+29)
GET_replicationcontrollers_p50     0.74 ±17%   0.73 ±17%     ~     (p=0.222 n=30+28)
GET_replicationcontrollers_p90     1.04 ±25%   1.01 ±27%     ~     (p=0.231 n=30+29)
GET_replicationcontrollers_p99     12.1 ±81%  10.0 ±145%     ~     (p=0.063 n=28+29)
GET_pods_p50                       0.78 ±12%   0.77 ±10%     ~     (p=0.178 n=30+28)
GET_pods_p90                       1.06 ±19%   1.02 ±19%     ~     (p=0.120 n=29+28)
GET_pods_p99                       3.92 ±43%   2.45 ±38%  -37.55%  (p=0.000 n=27+25)
LIST_services_p50                  0.20 ±13%   0.20 ±16%     ~     (p=0.854 n=28+29)
LIST_services_p90                  0.28 ±15%   0.27 ±14%     ~     (p=0.219 n=29+28)
LIST_services_p99                  0.49 ±20%   0.47 ±24%     ~     (p=0.140 n=29+29)
LIST_endpoints_p50                 0.19 ±14%   0.19 ±15%     ~     (p=0.709 n=29+29)
LIST_endpoints_p90                 0.26 ±16%   0.26 ±13%     ~     (p=0.274 n=29+28)
LIST_endpoints_p99                 0.46 ±24%   0.44 ±21%     ~     (p=0.111 n=29+29)
LIST_horizontalpodautoscalers_p50  0.16 ±15%   0.15 ±13%     ~     (p=0.253 n=30+27)
LIST_horizontalpodautoscalers_p90  0.22 ±24%   0.21 ±16%     ~     (p=0.152 n=30+28)
LIST_horizontalpodautoscalers_p99  0.31 ±33%   0.31 ±38%     ~     (p=0.817 n=28+29)
LIST_daemonsets_p50                0.16 ±20%   0.15 ±11%     ~     (p=0.135 n=30+27)
LIST_daemonsets_p90                0.22 ±18%   0.21 ±25%     ~     (p=0.135 n=29+28)
LIST_daemonsets_p99                0.29 ±28%   0.29 ±32%     ~     (p=0.606 n=28+28)
LIST_jobs_p50                      0.16 ±16%   0.15 ±12%     ~     (p=0.375 n=29+28)
LIST_jobs_p90                      0.22 ±18%   0.21 ±16%     ~     (p=0.090 n=29+26)
LIST_jobs_p99                      0.31 ±28%   0.28 ±35%  -10.29%  (p=0.005 n=29+27)
LIST_deployments_p50               0.15 ±16%   0.15 ±13%     ~     (p=0.565 n=29+28)
LIST_deployments_p90               0.22 ±22%   0.21 ±19%     ~     (p=0.107 n=30+28)
LIST_deployments_p99               0.31 ±27%   0.29 ±34%     ~     (p=0.068 n=29+28)
LIST_namespaces_p50                0.21 ±25%   0.21 ±26%     ~     (p=0.768 n=29+27)
LIST_namespaces_p90                0.28 ±29%   0.26 ±25%     ~     (p=0.101 n=30+28)
LIST_namespaces_p99                0.30 ±48%   0.29 ±42%     ~     (p=0.339 n=30+29)
LIST_replicasets_p50               0.15 ±18%   0.15 ±16%     ~     (p=0.612 n=30+28)
LIST_replicasets_p90               0.22 ±19%   0.21 ±18%   -5.13%  (p=0.011 n=28+27)
LIST_replicasets_p99               0.31 ±39%   0.28 ±29%     ~     (p=0.066 n=29+28)
LIST_persistentvolumes_p50         0.16 ±23%   0.15 ±21%     ~     (p=0.124 n=30+29)
LIST_persistentvolumes_p90         0.21 ±23%   0.20 ±23%     ~     (p=0.092 n=30+25)
LIST_persistentvolumes_p99         0.21 ±24%   0.20 ±23%     ~     (p=0.053 n=30+25)
LIST_resourcequotas_p50            0.16 ±12%   0.16 ±13%     ~     (p=0.175 n=27+28)
LIST_resourcequotas_p90            0.20 ±22%   0.20 ±24%     ~     (p=0.388 n=30+28)
LIST_resourcequotas_p99            0.22 ±24%   0.22 ±23%     ~     (p=0.575 n=30+28)
LIST_persistentvolumeclaims_p50    0.15 ±21%   0.15 ±29%     ~     (p=0.079 n=30+28)
LIST_persistentvolumeclaims_p90    0.19 ±26%   0.18 ±34%     ~     (p=0.446 n=29+29)
LIST_persistentvolumeclaims_p99    0.19 ±26%   0.18 ±34%     ~     (p=0.446 n=29+29)
LIST_pods_p50                      68.0 ±16%   56.3 ± 9%  -17.19%  (p=0.000 n=29+28)
LIST_pods_p90                       119 ±19%     93 ± 8%  -21.88%  (p=0.000 n=28+28)
LIST_pods_p99                       230 ±18%    202 ±14%  -12.13%  (p=0.000 n=27+28)
```
2016-04-27 08:32:18 -07:00
k8s-merge-robot 32121e344b Merge pull request #24514 from derekwaynecarr/pod_quota_fix
Automatic merge from submit-queue

Quota ignores pod compute resources on updates

Scenario:

1. define a quota Q that tracks memory and cpu
2. create pod P that uses memory=100Mi, cpu=100m
3. update pod P to use memory=50Mi,cpu=10m

Expected Results:
Step 3 should fail with validation error.
Quota Q should not have changed.

Actual Results:
Step 3 fails validation, but quota Q is decremented to have memory usage down 50Mi and cpu usage down 40m.  This is because the quota was getting updated even though the pod was going to fail validation.

Fix:
Quota should only support modifying pod compute resources when pods themselves support modifying their compute resources.

This also fixes https://github.com/kubernetes/kubernetes/issues/24352

/cc @smarterclayton - this is what we discussed.

fyi: @kubernetes/rh-cluster-infra
2016-04-27 06:27:51 -07:00
k8s-merge-robot a8d9a8dafd Merge pull request #24851 from pmorie/master-test-loc
Automatic merge from submit-queue

Reduce LOC in third party controller test

Extract method refactor to make this test a little more readable

@kubernetes/sig-api-machinery
2016-04-27 05:53:33 -07:00
k8s-merge-robot fc8fa69815 Merge pull request #24582 from xiangpengzhao/master
Automatic merge from submit-queue

Improve error messages in jwt_test.go
2016-04-27 05:53:32 -07:00
k8s-merge-robot 8dfb6ebc31 Merge pull request #24360 from freehan/svcflakefix1
Automatic merge from submit-queue

only close new ports upon iptables-restore failure

fixes: #24357
2016-04-27 04:42:13 -07:00
Marcin Wielgus 41dde20410 Make DrainOptions.getPodsForDeletion public to be reused in ClusterAutoscaler 2016-04-27 11:47:34 +02:00
Harry Zhang d6f26b68bc Use expiration cache for version check 2016-04-27 05:42:50 -04:00
k8s-merge-robot a907794ce3 Merge pull request #24833 from a-robinson/lbevent
Automatic merge from submit-queue

Fix DeletingLoadBalancer event generation.

release-note:
```release-note
Fix DeletingLoadBalancer event generation.
```

Also patch up a log statement to log the service's namespace and name
rather than potentially just logging `kind:"" apiVersion:""`.

It doesn't work as written because `service` is always nil on this line. If it wasn't, then we wouldn't have taken this branch. `deltaService` is what contains the info that we have about the service.

Example of how the event generation fails as currently written:
```
E0426 22:18:41.726835      10 event.go:257] Could not construct reference to: '&api.Service{TypeMeta:unversioned.TypeMeta{Kind:"", APIVersion:""}, ObjectMeta:api.ObjectMeta{Name:"", GenerateName:"", Namespace:"", SelfLink:"", UID:"", ResourceVersion:"", Generation:0, CreationTimestamp:unversioned.Time{Time:time.Time{sec:0, nsec:0, loc:(*time.Location)(nil)}}, DeletionTimestamp:(*unversioned.Time)(nil), DeletionGracePeriodSeconds:(*int64)(nil), Labels:map[string]string(nil), Annotations:map[string]string(nil)}, Spec:api.ServiceSpec{Type:"", Ports:[]api.ServicePort(nil), Selector:map[string]string(nil), ClusterIP:"", ExternalIPs:[]string(nil), LoadBalancerIP:"", SessionAffinity:""}, Status:api.ServiceStatus{LoadBalancer:api.LoadBalancerStatus{Ingress:[]api.LoadBalancerIngress(nil)}}}' due to: 'selfLink was empty, can't make reference'. Will not report event: 'Normal' 'DeletingLoadBalancer' 'Deleting load balancer'
```
2016-04-27 01:36:20 -07:00
k8s-merge-robot b7e4672db9 Merge pull request #23847 from XiaoningDing/federation-apiobject-cluster
Automatic merge from submit-queue

Federation apiobject cluster

add federation api group
add cluster api object and registry
~~generate cluster client~~ moved to #24117
update scripts to generate files for /federation

#19313 #23653 #23554
@nikhiljindal  @quinton-hoole, @deepak-vij, @XiaoningDing, @alfred-huangjian @mfanjie @huangyuqi @colhom
2016-04-27 00:26:22 -07:00
Paul Morie c386850d23 Reduce LOC in third party controller test 2016-04-27 02:50:46 -04:00
k8s-merge-robot af71fa72e7 Merge pull request #23574 from deads2k/add-extra
Automatic merge from submit-queue

add user.Info.GetExtra

I found myself wanting this field (or something like it), when trying to plumb the information about which scopes a particular token has.

Only the token authenticators have that information and I don't want tokens to leak past the authenticator.  I thought about extending the `authenticator.Token` interface to include scopes (`[]string`), but that felt a little specific for what I wanted to do.  I came up with this as an alternative.

It allows the token authenticator to fill in the information and authorizers already get handed the `user.Info`.  It means that implementors can choose to tie the layers together if they wish, using whatever data they think is best.  

@kubernetes/kube-iam
2016-04-26 21:14:53 -07:00
Alex Robinson ed15931935 Fix DeletingLoadBalancer event generation.
Also patch up a log statement to log the service's namespace and name
rather than potentially just logging `kind:"" apiVersion:""`.
2016-04-27 00:27:55 +00:00
derekwaynecarr ec5670fd73 Fix function name typo in kubelet 2016-04-26 17:29:44 -04:00
Minhan Xia 0d36dc7000 added test for revertPorts 2016-04-26 14:23:06 -07:00
Minhan Xia 56ad718008 only close new ports upon iptables-restore failure 2016-04-26 14:23:06 -07:00
Minhan Xia c8470c49ac add mutex for kubenet 2016-04-26 13:58:10 -07:00
k8s-merge-robot 373a3ece84 Merge pull request #24475 from k82/k8s-24411
Automatic merge from submit-queue

Clarify `kubectl get service` output.

Pull request for #24411 .
2016-04-26 13:45:09 -07:00
Clayton Coleman 236925be87
Avoid allocations and a reflect.Call in conversion
reflect.Call is fairly expensive, performing 8 allocations and having to
set up a call stack. Using a fairly straightforward to generate switch
statement, we can bypass that early in conversion (as long as the
function takes responsibility for invocation). We may also be able to
avoid an allocation for the conversion scope, but not positive yet.

```
benchmark                    old ns/op     new ns/op     delta
BenchmarkPodConversion-8     14713         12173         -17.26%

benchmark                    old allocs     new allocs     delta
BenchmarkPodConversion-8     80             72             -10.00%

benchmark                    old bytes     new bytes     delta
BenchmarkPodConversion-8     9133          8712          -4.61%
```
2016-04-26 16:42:12 -04:00
deads2k b4ebfd47c5 add user.Info.GetExtra 2016-04-26 15:08:34 -04:00
k8s-merge-robot c7a1e5da68 Merge pull request #24061 from timothysc/kvstore
Automatic merge from submit-queue

Renaming generic registry store from etcd->kvstore

This is part of issue #17546, in preparation for multiple backend storage facilities, renaming the registry structs to reflect.  

xref: #1957
2016-04-26 11:00:19 -07:00
k8s-merge-robot 96586e7c60 Merge pull request #23958 from petervo/byte-args
Automatic merge from submit-queue

kubectl: Allow []byte config fields to be set by the cli

Allows []byte config fields such as 'certificate-authority-data' to be set using `kubectl config set` commands.
2016-04-26 10:23:07 -07:00
k8s-merge-robot 55cb7cceb3 Merge pull request #23632 from stefwalter/parse-repository-tag-removed
Automatic merge from submit-queue

Fix use of docker removed ParseRepositoryTag() function

Docker has removed the ParseRepositoryTag() function in
leading to failures using the kubernetes Go client API.

Failure:

```
../k8s.io/kubernetes/pkg/util/parsers/parsers.go:30: undefined: parsers.ParseRepositoryTag
```
2016-04-26 09:49:25 -07:00
k8s-merge-robot f79c7d12c6 Merge pull request #24382 from smarterclayton/fix_rlqt
Automatic merge from submit-queue

RateLimitedQueue TestTryOrdering could fail under load

Remove the possibility of contention in the test by providing a
synthetic Now() function.

Fixes #24125
2016-04-26 08:40:58 -07:00
Timothy St. Clair 24b4286960 In preparation for new storage backends renaming generic registry store 2016-04-26 08:32:13 -05:00
deads2k 622932422d enable resource name and service account cases for impersonation 2016-04-26 09:31:43 -04:00
deads2k 0061479890 fully qualify admission resources and kinds 2016-04-26 07:55:33 -04:00
jianhuiz 1c1ad1ad3f add cluster registry 2016-04-26 02:06:47 -07:00
jianhuiz fcb241d05c add api group 'federation' and 'cluster' object 2016-04-26 02:05:51 -07:00
k8s-merge-robot a586177360 Merge pull request #23740 from dcbw/kubenet-shaper
Automatic merge from submit-queue

kubenet: hook pod bandwidth resources up to shaper

@bprashanth @thockin Last bit for shaping.
2016-04-25 22:15:42 -07:00
k8s-merge-robot cf38d68734 Merge pull request #23595 from vishh/image-accounting
Automatic merge from submit-queue

Collect and expose runtime's image storage usage via Kubelet's /stats/summary endpoint

This information is useful to users since docker images are typically not stored on the root filesystem.

Kubelet will also consume this feature in the future to decide is evicting images will help with disk usage on the nodes.

cc @kubernetes/sig-node
2016-04-25 21:34:30 -07:00
k8s-merge-robot 293b0d0815 Merge pull request #23493 from soltysh/move_job_internals
Automatic merge from submit-queue

Move internal types of job from pkg/apis/extensions to pkg/apis/batch

This addressed the job part of #23216, this is still WIP. Will notify once finished. I'd like to have it in before starting working on ScheduledJob. 

@lavalamp @erictune fyi
2016-04-25 20:58:49 -07:00
k8s-merge-robot b04f6ffc48 Merge pull request #24646 from nikhiljindal/removeMasterDep
Automatic merge from submit-queue

Move SSHTunneler to genericapiserver and remove federated-apiserver's dependency on pkg/master

cc @jianhuiz
2016-04-25 19:50:37 -07:00
Vishnu kannan e566948a75 Track image storage usage for docker containers
add image fs info to summary stats API.
Adding node e2e test for image stats.

Signed-off-by: Vishnu kannan <vishnuk@google.com>
2016-04-25 16:00:34 -07:00
Euan Kemp 941caa1372 rkt: Pass through os argument
This was lost in a rebase in #24496 and, while not required to build, is
required to function correctly.
2016-04-25 12:56:25 -07:00
Euan Kemp 7d34b0b09d kubelet: Remove redundant `Container.Created`
This has been supplanted by a) the DockerJSON.CreatedAt field and b) the
ContainerStatus.CreatedAt, where the first is used for creating the
second.

The `.Created` field was only written to as far as I can see.
2016-04-25 12:19:24 -07:00
Jeff Lowdermilk 1baa473ef2 kubectl rolling-update support for same image 2016-04-25 09:20:15 -07:00
zhouhaibing089 bf1a3f99c0 Uncomment the code that cause by #19254 2016-04-25 23:21:31 +08:00
Stef Walter 481dbca8bc Fix use of docker removed ParseRepositoryTag() function
Docker has removed the ParseRepositoryTag() function in
leading to failures using the kubernetes Go client API.

Lets use github.com/docker/distribution reference.ParseNamed()
instead.

Failure:

../k8s.io/kubernetes/pkg/util/parsers/parsers.go:30: undefined: parsers.ParseRepositoryTag
2016-04-25 11:37:10 +02:00
Wojciech Tyczynski c0020aff59 Merge pull request #24539 from smarterclayton/unify_stream_and_serial
Unify Streaming and normal Serializers
2016-04-25 11:25:16 +02:00
Maciej Szulik c470afc206 Generated changes for moving job internals from pkg/apis/extensions to pkg/apis/batch 2016-04-25 11:03:57 +02:00
Maciej Szulik a3b4447305 Move internal types of job from pkg/apis/extensions to pkg/apis/batch 2016-04-25 11:03:54 +02:00
Wojciech Tyczynski 1835c8528d Store node information in NodeInfo 2016-04-25 10:08:05 +02:00
Clayton Coleman 08f136b8d9
RateLimitedQueue TestTryOrdering could fail under load
Remove the possibility of contention in the test by providing a
synthetic Now() function.
2016-04-24 20:03:04 -04:00
derekwaynecarr 1ff0a793d7 Add generated artifacts for kubelet flags 2016-04-24 19:03:23 -04:00
derekwaynecarr 3c9ab576c2 Add kubelet flags for eviction threshold config 2016-04-24 19:03:23 -04:00
k8s-merge-robot 4f9e8729bf Merge pull request #23800 from resouer/image-refactor
Automatic merge from submit-queue

Refactor image related functions to use docker engine-api

ref #23563 

Hopes can do some help, cc @Random-Liu 

If it's ok, will add more work here.
2016-04-23 20:01:41 -07:00
k8s-merge-robot 30891c7f3f Merge pull request #24496 from euank/rkt-finished-at
Automatic merge from submit-queue

rkt: Return `FinishedAt` for pod

This is implemented via touching a file on stop as a hook in the systemd
unit. The ctime of this file is then used to get the `finishedAt` time
in the future.
In addition, this changes the `startedAt` and `createdAt` to use the api
server's results rather than the annotations it previously used.

It's possible we might want to move this into the api in the future.

Fixes #23887


I did the following manual testing:
```
$ cat ./examples/output/exit-output.yml 
apiVersion: v1
kind: Pod
metadata:
  labels:
    name: exit
  name: exit-output
spec:
  restartPolicy: Never
  containers:
    - name: exit
      image: busybox
      command: ["sh", "-c", "echo Exiting in 60; sleep 60; echo goodbye"]
$ kubectl create -f ./examples/exit/exit-output.yaml
$ # wait
$ kubectl describe pod exit-output | grep State -A 4
    State:		Terminated
      Reason:		Completed
      Exit Code:	0
      Started:		Tue, 19 Apr 2016 13:23:13 -0700
      Finished:		Tue, 19 Apr 2016 13:24:13 -0700
$ kubectl logs exit-output
Exiting in 60
goodbye
```

I double checked as well that the file at `/var/lib/kubelet/pods/$id/finished-$id` existed and looked as expected.

This is related to https://github.com/coreos/rkt/issues/1789#issuecomment-207111814 and follows https://github.com/kubernetes/kubernetes/pull/24367 + https://github.com/coreos/rkt/issues/2445

cc @jonboulle @iaguis @yifan-gu @kubernetes/sig-node
2016-04-23 18:29:07 -07:00
k8s-merge-robot 0d4b039d87 Merge pull request #24474 from deads2k/fix-version-registration
Automatic merge from submit-queue

stop changing the root path of the root webservice

We shouldn't mutate the root path of the root webservice (see usage).  Just write the path we want.
2016-04-23 17:51:56 -07:00
k8s-merge-robot ea15d792a1 Merge pull request #24470 from deads2k/shared-cache-02
Automatic merge from submit-queue

update controllers watching all pods to share an informer

This plumbs the shared pod informer through the various controllers to avoid duplicated watches.
2016-04-23 17:18:47 -07:00
k8s-merge-robot f583174d76 Merge pull request #24421 from deads2k/fix-admission
Automatic merge from submit-queue

let admission plugins indicate they want nothing

An admission plugin can return `nil, nil` for construction.  This is useful for dealing with cases where the `config` passed to you effectively means, "no work".  The calling code already handles this.

@derekwaynecarr
2016-04-23 12:04:19 -07:00
k8s-merge-robot de9c1a2a51 Merge pull request #24247 from sdminonne/service_loadbalancer_quotas
Automatic merge from submit-queue

Adding loadBalancer services to quota system

@derekwaynecarr follow up to #22154.
2016-04-23 10:22:45 -07:00
Harry Zhang a3939473d3 Refactor PullImage RemoveImage methods
Refactor image remove
2016-04-23 10:33:47 -04:00
Harry Zhang 3918eee5bf Refactor InspectImage method 2016-04-23 16:37:15 +08:00
Harry Zhang 7ecb44fe16 Refactor list image to use new api 2016-04-23 16:37:15 +08:00
k8s-merge-robot 2ec908083b Merge pull request #24674 from gmarek/maxpods
Automatic merge from submit-queue

Enforce --max-pods in kubelet admission; previously was only enforced in scheduler

This is an ugly hack - I spent some time trying to understand what one NodeInfo has in common with the other one, but at some point decided that I just don't have time to do that.

Fixes #24262
Fixes #20263

cc @HaiyangDING @lavalamp
2016-04-22 23:00:20 -07:00
petervo 4f9d3ace5d kubectl: Allow []byte config fields to be set by the cli
Allows []byte config fields such as 'certificate-authority-data'
to be set using `kubectl config set` commands.
2016-04-22 15:53:24 -07:00
Yifan Gu a12a7c2a2c rkt: Add post-start hook support.
This adds a poll-and-timeout procedure after the pod is
started, to make sure the post-start hooks execute when the
container is actually running.

This is a temporal workaround for implementing post-hooks,
a long term solution is to use lifecycle event to trigger
those hooks, see https://github.com/kubernetes/kubernetes/issues/23084.

Also this fixes a bug of getting container ID for a non-running
container when running pre-stop hook.
2016-04-22 15:38:05 -07:00
Euan Kemp a6718f5969 rkt: Implement pod `FinishedAt`
This is implemented via touching a file on stop as a hook in the systemd
unit. The ctime of this file is then used to get the `finishedAt` time
in the future.
In addition, this changes the `startedAt` and `createdAt` to use the api
server's results rather than the annotations it previously used.

It's possible we might want to move this into the api in the future.

Fixes #23887
2016-04-22 15:34:55 -07:00
gmarek e0712f7e57 Fix MaxPods feature in scheduler 2016-04-22 22:49:50 +02:00
nikhiljindal f9f1e21e08 Moving master.SSHTunneler to genericapiserver 2016-04-22 11:47:05 -07:00
k8s-merge-robot aa4da07157 Merge pull request #24631 from goltermann/spell
Automatic merge from submit-queue

Fix a few typos in comments
2016-04-22 09:45:46 -07:00
Clayton Coleman 668fae253f Generated spec and docs 2016-04-22 11:07:33 -04:00
Clayton Coleman 3111985564 Handle streaming serializers more consistently
Add tests to watch behavior in both protocols (http and websocket)
against all 3 media types. Adopt the
`application/vnd.kubernetes.protobuf;stream=watch` media type for the
content that comes back from a watch call so that it can be
distinguished from a Status result.
2016-04-22 11:07:24 -04:00
k8s-merge-robot 88a68e99f3 Merge pull request #24390 from smarterclayton/byte_slice
Automatic merge from submit-queue

Default conversion for byte slices is incorrect

Nil slices are getting allocated, which is incorrect and changes
behavior in some cases.

   []byte(nil) -> []byte(nil)

@wojtek-t
2016-04-22 07:07:32 -07:00
k8s-merge-robot 66dc446ba0 Merge pull request #24347 from derekwaynecarr/fix_configmap
Automatic merge from submit-queue

Fix ConfigMapList.Items to not use omitempty

Fixes https://github.com/kubernetes/kubernetes/issues/24335
2016-04-22 04:07:44 -07:00
k8s-merge-robot 10e697d1f9 Merge pull request #24638 from hongchaodeng/w
Automatic merge from submit-queue

etcd3/watcher: cancelling context shouldn't return error

Fixes #24528
2016-04-22 01:50:18 -07:00
k8s-merge-robot 495251b983 Merge pull request #24166 from gmarek/client
Automatic merge from submit-queue

All clients under ClientSet share one RateLimiter.

Currently we create a rate limiter for each client in client set. It makes the reasoning about rate limiting behavior much harder. This PR changes this behavior and now all clients in the set share single rate limiter. Ref. #24157

cc @lavalamp @wojtek-t
2016-04-21 22:31:23 -07:00
Hongchao Deng b0f4517e65 etcd3/watcher: cancelling context shouldn't return error 2016-04-22 12:23:04 +08:00
k8s-merge-robot 06c2db4fe2 Merge pull request #23907 from Random-Liu/all-but-image-related-functions
Automatic merge from submit-queue

Kubelet: Refactor all but image related functions in DockerInterface

For #23563.
Based on #23699 and #23844.

Only last 3 commits are new. This PR refactored all functions except image related functions, including:
* CreateExec
* StartExec
* InspectExec
* AttachToContainer
* Logs
* Info
* Version

@kubernetes/sig-node
2016-04-21 20:57:38 -07:00
k8s-merge-robot f4beccf000 Merge pull request #23066 from cjcullen/clientplugin
Automatic merge from submit-queue

Client auth provider plugin framework

Allows client plugins to modify the underlying transport to, for example, add custom authorization headers.
2016-04-21 17:30:28 -07:00
k8s-merge-robot 06160b6abe Merge pull request #22023 from mkulke/rackspace-improvements
Automatic merge from submit-queue

Rackspace improvements (OpenStack Cinder)

This adds PV support via Cinder on Rackspace clusters. Rackspace Cloud Block Storage is pretty much vanilla OpenStack Cinder, so there is no need for a separate Volume Plugin. Instead I refactored the Cinder/OpenStack interaction a bit (by introducing a CinderProvider Interface and moving the device path detection logic to the OpenStack part).

Right now this is limited to `AttachDisk` and `DetachDisk`. Creation and deletion of Block Storage is not in scope of this PR.

Also the `ExternalID` and `InstanceID` cloud provider methods have been implemented for Rackspace.
2016-04-21 16:38:13 -07:00
k8s-merge-robot e3dab39df0 Merge pull request #21304 from tobad357/iscsi-mpio-support
Automatic merge from submit-queue

Add mpio support for iscsi

This allows the iscsi volume to check if a iscsi device belongs to a mpio device
If it does belong to the device then we make sure we mount the mpio device instead of
the raw device. 
The code is based on the current FibreChannel volume support for mpio

example
/dev/disk/by-path/iqn-example.com.2999 -> /dev/sde
Then we check
/sys/block/[dm-X]/slaves/xx
until we find the [dm-X] containing /dev/sde and mount it

Additional work that can be done in future
1. Add multiple portal support to iscsi
2. Move the FibreChannel volume provider to use the code that has been extracted
2016-04-21 15:40:50 -07:00
goltermann dddc6cb6c8 Fix a few spellings. 2016-04-21 15:16:42 -07:00
derekwaynecarr 2b9cfd414d Add utility for determining qos of a pod 2016-04-21 17:15:17 -04:00
Russ Cox 58629a28e4 pkg/registry/pod: avoid allocation in common pod search
PodToSelectableFields creates a map of field attributes
for a particular pod filter query to use. If the result
of the query does not depend on the fields at all, avoid
creating the map.

This is the source of about half the allocated memory
(by byte volume) during the kubemark benchmark, and it
is in turn the main driver of CPU usage during the benchmark,
because of the many background pod watches going on,
as well as the occasional list pods.

These benchmarks for 1000-node kubemark show the difference
from my previous CL (caching timers) to this CL:

name                               old ms/op   new ms/op   delta
LIST_nodes_p50                       124 ±13%    121 ± 9%     ~     (p=0.136 n=29+27)
LIST_nodes_p90                       278 ±15%    266 ±12%   -4.26%  (p=0.031 n=29+27)
LIST_nodes_p99                       405 ±19%    400 ±14%     ~     (p=0.864 n=28+28)
LIST_pods_p50                       65.3 ±13%   56.3 ± 9%  -13.75%  (p=0.000 n=29+28)
LIST_pods_p90                        115 ±12%     93 ± 8%  -18.75%  (p=0.000 n=27+28)
LIST_pods_p99                        226 ±21%    202 ±14%  -10.52%  (p=0.000 n=28+28)
LIST_replicationcontrollers_p50     26.6 ±43%   26.2 ±54%     ~     (p=0.487 n=29+29)
LIST_replicationcontrollers_p90     68.7 ±63%   68.6 ±59%     ~     (p=0.931 n=29+28)
LIST_replicationcontrollers_p99      173 ±41%    177 ±49%     ~     (p=0.618 n=28+29)
PUT_replicationcontrollers_p50      5.83 ±36%   5.94 ±32%     ~     (p=0.818 n=28+29)
PUT_replicationcontrollers_p90      15.9 ± 6%   15.5 ± 6%   -2.23%  (p=0.019 n=28+29)
PUT_replicationcontrollers_p99      56.7 ±41%   39.5 ±55%  -30.29%  (p=0.000 n=28+29)
DELETE_pods_p50                     24.3 ±17%   24.3 ±13%     ~     (p=0.855 n=28+29)
DELETE_pods_p90                     30.6 ± 0%   30.7 ± 1%     ~     (p=0.140 n=28+29)
DELETE_pods_p99                     56.3 ±27%   54.2 ±23%     ~     (p=0.188 n=28+27)
PUT_nodes_p50                       14.9 ± 1%   14.8 ± 2%     ~     (p=0.781 n=28+27)
PUT_nodes_p90                       16.4 ± 2%   16.3 ± 2%     ~     (p=0.321 n=28+28)
PUT_nodes_p99                       44.6 ±42%   41.3 ±35%     ~     (p=0.361 n=29+28)
POST_replicationcontrollers_p50     6.33 ±23%   6.34 ±20%     ~     (p=0.993 n=28+28)
POST_replicationcontrollers_p90     15.2 ± 6%   15.0 ± 5%     ~     (p=0.106 n=28+29)
POST_replicationcontrollers_p99     53.4 ±52%   32.9 ±46%  -38.41%  (p=0.000 n=27+27)
POST_pods_p50                       9.33 ±13%   8.95 ±16%     ~     (p=0.069 n=29+29)
POST_pods_p90                       16.3 ± 4%   16.1 ± 4%   -1.43%  (p=0.044 n=29+29)
POST_pods_p99                       28.4 ±23%   26.4 ±12%   -7.05%  (p=0.004 n=29+28)
DELETE_replicationcontrollers_p50   2.50 ±13%   2.50 ±13%     ~     (p=0.649 n=29+28)
DELETE_replicationcontrollers_p90   11.7 ±10%   11.8 ±13%     ~     (p=0.863 n=28+28)
DELETE_replicationcontrollers_p99   19.0 ±22%   19.1 ±21%     ~     (p=0.818 n=28+29)
PUT_pods_p50                        10.3 ± 5%   10.2 ± 5%     ~     (p=0.235 n=28+27)
PUT_pods_p90                        16.0 ± 1%   16.0 ± 1%     ~     (p=0.380 n=29+28)
PUT_pods_p99                        21.6 ±14%   20.9 ± 9%   -3.15%  (p=0.010 n=28+27)
POST_bindings_p50                   8.98 ±17%   8.92 ±15%     ~     (p=0.666 n=29+28)
POST_bindings_p90                   16.5 ± 2%   16.5 ± 3%     ~     (p=0.840 n=26+29)
POST_bindings_p99                   21.4 ± 5%   21.1 ± 4%   -1.21%  (p=0.049 n=27+28)
GET_nodes_p90                       1.18 ±19%   1.14 ±24%     ~     (p=0.137 n=29+29)
GET_nodes_p99                       8.29 ±40%   7.50 ±46%     ~     (p=0.106 n=28+29)
GET_replicationcontrollers_p90      1.03 ±21%   1.01 ±27%     ~     (p=0.489 n=29+29)
GET_replicationcontrollers_p99     10.0 ±123%  10.0 ±145%     ~     (p=0.794 n=28+29)
GET_pods_p90                        1.08 ±21%   1.02 ±19%     ~     (p=0.083 n=29+28)
GET_pods_p99                        2.81 ±39%   2.45 ±38%  -12.78%  (p=0.021 n=28+25)

Overall the two CLs combined have this effect:

name                               old ms/op  new ms/op   delta
LIST_nodes_p50                      127 ±16%    121 ± 9%   -4.58%  (p=0.000 n=29+27)
LIST_nodes_p90                      326 ±12%    266 ±12%  -18.48%  (p=0.000 n=29+27)
LIST_nodes_p99                      453 ±11%    400 ±14%  -11.79%  (p=0.000 n=29+28)
LIST_replicationcontrollers_p50    29.4 ±49%   26.2 ±54%     ~     (p=0.085 n=30+29)
LIST_replicationcontrollers_p90    83.0 ±78%   68.6 ±59%  -17.33%  (p=0.013 n=30+28)
LIST_replicationcontrollers_p99     216 ±43%    177 ±49%  -17.68%  (p=0.000 n=29+29)
DELETE_pods_p50                    24.5 ±14%   24.3 ±13%     ~     (p=0.562 n=30+29)
DELETE_pods_p90                    30.7 ± 1%   30.7 ± 1%   -0.30%  (p=0.011 n=29+29)
DELETE_pods_p99                    77.2 ±34%   54.2 ±23%  -29.76%  (p=0.000 n=30+27)
PUT_replicationcontrollers_p50     5.86 ±26%   5.94 ±32%     ~     (p=0.734 n=29+29)
PUT_replicationcontrollers_p90     15.8 ± 7%   15.5 ± 6%   -2.06%  (p=0.010 n=29+29)
PUT_replicationcontrollers_p99     57.8 ±35%   39.5 ±55%  -31.60%  (p=0.000 n=29+29)
PUT_nodes_p50                      14.9 ± 2%   14.8 ± 2%   -0.68%  (p=0.012 n=30+27)
PUT_nodes_p90                      16.5 ± 1%   16.3 ± 2%   -0.90%  (p=0.000 n=27+28)
PUT_nodes_p99                      57.9 ±47%   41.3 ±35%  -28.61%  (p=0.000 n=30+28)
POST_replicationcontrollers_p50    6.35 ±29%   6.34 ±20%     ~     (p=0.944 n=30+28)
POST_replicationcontrollers_p90    15.4 ± 5%   15.0 ± 5%   -2.18%  (p=0.001 n=29+29)
POST_replicationcontrollers_p99    52.2 ±71%   32.9 ±46%  -36.99%  (p=0.000 n=29+27)
POST_pods_p50                      8.99 ±13%   8.95 ±16%     ~     (p=0.903 n=30+29)
POST_pods_p90                      16.2 ± 4%   16.1 ± 4%     ~     (p=0.287 n=29+29)
POST_pods_p99                      30.9 ±21%   26.4 ±12%  -14.73%  (p=0.000 n=28+28)
POST_bindings_p50                  9.34 ±12%   8.92 ±15%   -4.54%  (p=0.013 n=30+28)
POST_bindings_p90                  16.6 ± 1%   16.5 ± 3%   -0.73%  (p=0.017 n=28+29)
POST_bindings_p99                  23.5 ± 9%   21.1 ± 4%  -10.09%  (p=0.000 n=27+28)
PUT_pods_p50                       10.8 ±11%   10.2 ± 5%   -5.47%  (p=0.000 n=30+27)
PUT_pods_p90                       16.1 ± 1%   16.0 ± 1%   -0.64%  (p=0.000 n=29+28)
PUT_pods_p99                       23.4 ± 9%   20.9 ± 9%  -10.93%  (p=0.000 n=28+27)
DELETE_replicationcontrollers_p50  2.42 ±16%   2.50 ±13%     ~     (p=0.054 n=29+28)
DELETE_replicationcontrollers_p90  11.5 ±12%   11.8 ±13%     ~     (p=0.141 n=30+28)
DELETE_replicationcontrollers_p99  19.5 ±21%   19.1 ±21%     ~     (p=0.397 n=29+29)
GET_nodes_p50                      0.77 ±10%   0.76 ±10%     ~     (p=0.317 n=28+28)
GET_nodes_p90                      1.20 ±16%   1.14 ±24%   -4.66%  (p=0.036 n=28+29)
GET_nodes_p99                      11.4 ±48%    7.5 ±46%  -34.28%  (p=0.000 n=28+29)
GET_replicationcontrollers_p50     0.74 ±17%   0.73 ±17%     ~     (p=0.222 n=30+28)
GET_replicationcontrollers_p90     1.04 ±25%   1.01 ±27%     ~     (p=0.231 n=30+29)
GET_replicationcontrollers_p99     12.1 ±81%  10.0 ±145%     ~     (p=0.063 n=28+29)
GET_pods_p50                       0.78 ±12%   0.77 ±10%     ~     (p=0.178 n=30+28)
GET_pods_p90                       1.06 ±19%   1.02 ±19%     ~     (p=0.120 n=29+28)
GET_pods_p99                       3.92 ±43%   2.45 ±38%  -37.55%  (p=0.000 n=27+25)
LIST_services_p50                  0.20 ±13%   0.20 ±16%     ~     (p=0.854 n=28+29)
LIST_services_p90                  0.28 ±15%   0.27 ±14%     ~     (p=0.219 n=29+28)
LIST_services_p99                  0.49 ±20%   0.47 ±24%     ~     (p=0.140 n=29+29)
LIST_endpoints_p50                 0.19 ±14%   0.19 ±15%     ~     (p=0.709 n=29+29)
LIST_endpoints_p90                 0.26 ±16%   0.26 ±13%     ~     (p=0.274 n=29+28)
LIST_endpoints_p99                 0.46 ±24%   0.44 ±21%     ~     (p=0.111 n=29+29)
LIST_horizontalpodautoscalers_p50  0.16 ±15%   0.15 ±13%     ~     (p=0.253 n=30+27)
LIST_horizontalpodautoscalers_p90  0.22 ±24%   0.21 ±16%     ~     (p=0.152 n=30+28)
LIST_horizontalpodautoscalers_p99  0.31 ±33%   0.31 ±38%     ~     (p=0.817 n=28+29)
LIST_daemonsets_p50                0.16 ±20%   0.15 ±11%     ~     (p=0.135 n=30+27)
LIST_daemonsets_p90                0.22 ±18%   0.21 ±25%     ~     (p=0.135 n=29+28)
LIST_daemonsets_p99                0.29 ±28%   0.29 ±32%     ~     (p=0.606 n=28+28)
LIST_jobs_p50                      0.16 ±16%   0.15 ±12%     ~     (p=0.375 n=29+28)
LIST_jobs_p90                      0.22 ±18%   0.21 ±16%     ~     (p=0.090 n=29+26)
LIST_jobs_p99                      0.31 ±28%   0.28 ±35%  -10.29%  (p=0.005 n=29+27)
LIST_deployments_p50               0.15 ±16%   0.15 ±13%     ~     (p=0.565 n=29+28)
LIST_deployments_p90               0.22 ±22%   0.21 ±19%     ~     (p=0.107 n=30+28)
LIST_deployments_p99               0.31 ±27%   0.29 ±34%     ~     (p=0.068 n=29+28)
LIST_namespaces_p50                0.21 ±25%   0.21 ±26%     ~     (p=0.768 n=29+27)
LIST_namespaces_p90                0.28 ±29%   0.26 ±25%     ~     (p=0.101 n=30+28)
LIST_namespaces_p99                0.30 ±48%   0.29 ±42%     ~     (p=0.339 n=30+29)
LIST_replicasets_p50               0.15 ±18%   0.15 ±16%     ~     (p=0.612 n=30+28)
LIST_replicasets_p90               0.22 ±19%   0.21 ±18%   -5.13%  (p=0.011 n=28+27)
LIST_replicasets_p99               0.31 ±39%   0.28 ±29%     ~     (p=0.066 n=29+28)
LIST_persistentvolumes_p50         0.16 ±23%   0.15 ±21%     ~     (p=0.124 n=30+29)
LIST_persistentvolumes_p90         0.21 ±23%   0.20 ±23%     ~     (p=0.092 n=30+25)
LIST_persistentvolumes_p99         0.21 ±24%   0.20 ±23%     ~     (p=0.053 n=30+25)
LIST_resourcequotas_p50            0.16 ±12%   0.16 ±13%     ~     (p=0.175 n=27+28)
LIST_resourcequotas_p90            0.20 ±22%   0.20 ±24%     ~     (p=0.388 n=30+28)
LIST_resourcequotas_p99            0.22 ±24%   0.22 ±23%     ~     (p=0.575 n=30+28)
LIST_persistentvolumeclaims_p50    0.15 ±21%   0.15 ±29%     ~     (p=0.079 n=30+28)
LIST_persistentvolumeclaims_p90    0.19 ±26%   0.18 ±34%     ~     (p=0.446 n=29+29)
LIST_persistentvolumeclaims_p99    0.19 ±26%   0.18 ±34%     ~     (p=0.446 n=29+29)
LIST_pods_p50                      68.0 ±16%   56.3 ± 9%  -17.19%  (p=0.000 n=29+28)
LIST_pods_p90                       119 ±19%     93 ± 8%  -21.88%  (p=0.000 n=28+28)
LIST_pods_p99                       230 ±18%    202 ±14%  -12.13%  (p=0.000 n=27+28)
2016-04-21 15:53:47 -04:00
Russ Cox 6a19e46ed6 pkg/storage: cache timers
A previous change here replaced time.After with an explicit
timer that can be stopped, to avoid filling up the active timer list
with timers that are no longer needed. But an even better fix is to
reuse the timers across calls, to avoid filling the allocated heap
with work for the garbage collector. On top of that, try a quick
non-blocking send to avoid the timer entirely.

For the e2e 1000-node kubemark test, basically everything gets faster,
some things significantly so. The 90th and 99th percentile for LIST nodes
in particular are the worst case that has caused SLO/SLA problems
in the past, and this reduces 99th percentile by 10%.

name                               old ms/op  new ms/op   delta
LIST_nodes_p50                      127 ±16%    124 ±13%     ~     (p=0.136 n=29+29)
LIST_nodes_p90                      326 ±12%    278 ±15%  -14.85%  (p=0.000 n=29+29)
LIST_nodes_p99                      453 ±11%    405 ±19%  -10.70%  (p=0.000 n=29+28)
LIST_replicationcontrollers_p50    29.4 ±49%   26.6 ±43%     ~     (p=0.176 n=30+29)
LIST_replicationcontrollers_p90    83.0 ±78%   68.7 ±63%  -17.30%  (p=0.020 n=30+29)
LIST_replicationcontrollers_p99     216 ±43%    173 ±41%  -19.53%  (p=0.000 n=29+28)
DELETE_pods_p50                    24.5 ±14%   24.3 ±17%     ~     (p=0.562 n=30+28)
DELETE_pods_p90                    30.7 ± 1%   30.6 ± 0%   -0.44%  (p=0.000 n=29+28)
DELETE_pods_p99                    77.2 ±34%   56.3 ±27%  -26.99%  (p=0.000 n=30+28)
PUT_replicationcontrollers_p50     5.86 ±26%   5.83 ±36%     ~     (p=1.000 n=29+28)
PUT_replicationcontrollers_p90     15.8 ± 7%   15.9 ± 6%     ~     (p=0.936 n=29+28)
PUT_replicationcontrollers_p99     57.8 ±35%   56.7 ±41%     ~     (p=0.725 n=29+28)
PUT_nodes_p50                      14.9 ± 2%   14.9 ± 1%   -0.55%  (p=0.020 n=30+28)
PUT_nodes_p90                      16.5 ± 1%   16.4 ± 2%   -0.60%  (p=0.040 n=27+28)
PUT_nodes_p99                      57.9 ±47%   44.6 ±42%  -23.02%  (p=0.000 n=30+29)
POST_replicationcontrollers_p50    6.35 ±29%   6.33 ±23%     ~     (p=0.957 n=30+28)
POST_replicationcontrollers_p90    15.4 ± 5%   15.2 ± 6%   -1.14%  (p=0.034 n=29+28)
POST_replicationcontrollers_p99    52.2 ±71%   53.4 ±52%     ~     (p=0.720 n=29+27)
POST_pods_p50                      8.99 ±13%   9.33 ±13%   +3.79%  (p=0.023 n=30+29)
POST_pods_p90                      16.2 ± 4%   16.3 ± 4%     ~     (p=0.113 n=29+29)
POST_pods_p99                      30.9 ±21%   28.4 ±23%   -8.26%  (p=0.001 n=28+29)
POST_bindings_p50                  9.34 ±12%   8.98 ±17%     ~     (p=0.083 n=30+29)
POST_bindings_p90                  16.6 ± 1%   16.5 ± 2%   -0.76%  (p=0.000 n=28+26)
POST_bindings_p99                  23.5 ± 9%   21.4 ± 5%   -8.98%  (p=0.000 n=27+27)
PUT_pods_p50                       10.8 ±11%   10.3 ± 5%   -4.67%  (p=0.000 n=30+28)
PUT_pods_p90                       16.1 ± 1%   16.0 ± 1%   -0.55%  (p=0.003 n=29+29)
PUT_pods_p99                       23.4 ± 9%   21.6 ±14%   -8.03%  (p=0.000 n=28+28)
DELETE_replicationcontrollers_p50  2.42 ±16%   2.50 ±13%     ~     (p=0.072 n=29+29)
DELETE_replicationcontrollers_p90  11.5 ±12%   11.7 ±10%     ~     (p=0.190 n=30+28)
DELETE_replicationcontrollers_p99  19.5 ±21%   19.0 ±22%     ~     (p=0.298 n=29+28)
GET_nodes_p90                      1.20 ±16%   1.18 ±19%     ~     (p=0.626 n=28+29)
GET_nodes_p99                      11.4 ±48%    8.3 ±40%  -27.31%  (p=0.000 n=28+28)
GET_replicationcontrollers_p90     1.04 ±25%   1.03 ±21%     ~     (p=0.682 n=30+29)
GET_replicationcontrollers_p99     12.1 ±81%  10.0 ±123%     ~     (p=0.135 n=28+28)
GET_pods_p90                       1.06 ±19%   1.08 ±21%     ~     (p=0.597 n=29+29)
GET_pods_p99                       3.92 ±43%   2.81 ±39%  -28.39%  (p=0.000 n=27+28)
LIST_pods_p50                      68.0 ±16%   65.3 ±13%     ~     (p=0.066 n=29+29)
LIST_pods_p90                       119 ±19%    115 ±12%     ~     (p=0.091 n=28+27)
LIST_pods_p99                       230 ±18%    226 ±21%     ~     (p=0.251 n=27+28)
2016-04-21 15:53:47 -04:00
k8s-merge-robot 34fc7f0401 Merge pull request #24461 from wojtek-t/enable_components_to_use_protobufs
Automatic merge from submit-queue

Allow components to use protobufs while talking to apiserver.
2016-04-21 12:46:17 -07:00
k8s-merge-robot 72e51dacfe Merge pull request #24034 from AdoHe/log_spam
Automatic merge from submit-queue

remove log spam from nodecontroller

@thockin @quinton-hoole ptal.
2016-04-21 12:11:05 -07:00
k8s-merge-robot 9d4eee63ab Merge pull request #24589 from derekwaynecarr/fix_shm
Automatic merge from submit-queue

docker daemon complains SHM size must be greater than 0

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

I am hitting this on Fedora 23 w/ docker 1.9.1 using systemd cgroup-driver.

```
$ docker version
Client:
 Version:         1.9.1
 API version:     1.21
 Package version: docker-1.9.1-9.gitee06d03.fc23.x86_64
 Go version:      go1.5.3
 Git commit:      ee06d03/1.9.1
 Built:           
 OS/Arch:         linux/amd64

Server:
 Version:         1.9.1
 API version:     1.21
 Package version: docker-1.9.1-9.gitee06d03.fc23.x86_64
 Go version:      go1.5.3
 Git commit:      ee06d03/1.9.1
 Built:           
 OS/Arch:         linux/amd64
```

Not sure why I am on the only one hitting it right now, but putting this out here for comment.

/cc @kubernetes/sig-node @kubernetes/rh-cluster-infra @smarterclayton
2016-04-21 12:11:03 -07:00
Random-Liu d981fee2ee Refactor Info and Version. 2016-04-21 12:02:50 -07:00
k8s-merge-robot 145917368a Merge pull request #24398 from caesarxuchao/fqresource-fake-client
Automatic merge from submit-queue

Make fake client actions use fully qualified resource

The output of a versioned clientset is version object. The fake client used to assume only internal objects will be returned. This PR removes this assumption by making fake actions initialized with a fully qualified resource instead of a resource string.

We have to regenerate fake clients in release_1_2 clientset to let it compile. For the test fakes, we are breaking the backwards compatibility promise.

Part of #24155.
2016-04-21 10:45:32 -07:00
gmarek b76bed0cc9 All clients under ClientSet share one RateLimiter. 2016-04-21 18:48:22 +02:00
derekwaynecarr cbf1cb81a9 SHM size must be greater than 0 2016-04-21 11:45:28 -04:00
Clayton Coleman 9ec92559e5 Merge pull request #24594 from wojtek-t/fix_protobuf_verifier
Fix verification script for proto-generation
2016-04-21 11:31:09 -04:00
k8s-merge-robot 85de6acadc Merge pull request #23208 from deads2k/fix-version-override
Automatic merge from submit-queue

make storage enablement, serialization, and location orthogonal

This allows a caller (command-line, config, code) to specify multiple separate pieces of config information regarding storage and have them properly composed at runtime.  The information provided is exposed through interfaces to allow alternate implementations, which allows us to change the expression of the config moving forward.  I also fixed up the types to be correct as I moved through.

The same options still exist, but they're composed slightly differently
 1. specify target etcd servers per Group or per GroupResource
 1. specify storage GroupVersions per Groups or per GroupResource
 1. specify etcd prefixes per GroupVersion or per GroupResource
 1. specify that multiple GroupResources share the same location in etcd
 1. enable GroupResources by GroupVersion or by GroupResource whitelist or GroupResource blacklist

The `storage.Interface` is built per GroupResource by:
 1. find the set of possible storage GroupResource based on the priority list of cohabitators
 1. choose a GroupResource from the set by looking at which Groups have the resource enabled
 1. find the target etcd server, etcd prefix, and storage encoding based on the GroupResource

The API server can have its resources separately enabled, but for now I've kept them linked.

@liggitt I think we need this (or something like it) to be able to go from config to these interfaces.  Given another round of refactoring, we may be able to reshape these to be more forward driving.

@smarterclayton this is important for rebasing and for a seamless 1.2 to 1.3 migration for us.
2016-04-21 08:24:29 -07:00
Wojciech Tyczynski 3f06755566 Regenerate protobuf files 2016-04-21 16:22:52 +02:00
deads2k 60fe17d338 update resource quota controller for shared informers 2016-04-21 08:20:39 -04:00
deads2k 8c4e3af1a3 switch job controller to shared informer 2016-04-21 08:20:39 -04:00
deads2k 8b707016f9 convert daemonset controller to SharedInformer 2016-04-21 08:20:39 -04:00
k8s-merge-robot 0a5d57a383 Merge pull request #24079 from hongchaodeng/comp
Automatic merge from submit-queue

etcd3 store: provide compactor util

What's this PR?
- Provides a util to compact keys in etcd.

Reason:
We want to save the most recent 10 minutes event history. It should be more than enough for slow watchers. It is not number based, so it can tolerate event bursts too. We do not want to save longer since the current storage API cannot take advantage of the multi-version key yet. We might keep a longer history in the future.
2016-04-21 05:19:54 -07:00
deads2k 6670b73b18 make storage enablement, serialization, and location orthogonal 2016-04-21 08:18:55 -04:00
Wojciech Tyczynski 31e2f8e485 Regenerate files 2016-04-21 14:12:13 +02:00
Wojciech Tyczynski d6896fa45a Allow setting content-type in binaries 2016-04-21 14:12:13 +02:00
k8s-merge-robot 767fa6913d Merge pull request #24118 from smarterclayton/proxy_args
Automatic merge from submit-queue

Allow Proxy to be initialized with store
2016-04-21 04:42:43 -07:00
k8s-merge-robot 09adffb318 Merge pull request #23317 from aanm/removing-ipv4-enforcement
Automatic merge from submit-queue

Remove requirement that Endpoints IPs be IPv4

Signed-off-by: André Martins <aanm90@gmail.com>

Release Note: The `Endpoints` API object now allows IPv6 addresses to be stored.  Other components of the system are not ready for IPv6 yet, and many cloud providers are not IPv6 compatible, but installations that use their own controller logic can now store v6 endpoints.
2016-04-21 03:34:50 -07:00
kulke ba4d74f3c7 Added Block Storage support to Rackspace provider, improved Node discovery. 2016-04-21 10:31:37 +02:00
Klaus Ma b6d2c2b295 Clarify kubectl output. 2016-04-21 15:35:32 +08:00
derekwaynecarr fd04ff1bd1 Generated artifacts for ConfigMapList change 2016-04-21 02:07:45 -04:00
derekwaynecarr 155c1a4465 ConfigMapList.Items should not be omitempty 2016-04-21 02:07:45 -04:00
Clayton Coleman 6ab9cfcc39 Generate protobuf marshallers for new apps group 2016-04-21 01:39:50 -04:00
Xiangpeng Zhao c381a7b61e Improve error messages in jwt_test.go
Fix typos and add more info to error messages.
2016-04-21 11:37:14 +08:00
Chao Xu 8537095415 use fully qualified resource in fake clients actions 2016-04-20 19:44:40 -07:00
k8s-merge-robot f8d4f6157f Merge pull request #24570 from hongchaodeng/w
Automatic merge from submit-queue

watcher test: print more info for debugging

ref: #24528

This will print out more info to dig out the root cause.
2016-04-20 19:01:10 -07:00
Prashanth Balasubramanian 0ac10c6cc2 PetSet type, apps apigroup 2016-04-20 18:49:31 -07:00
k8s-merge-robot cee4273e43 Merge pull request #24374 from smarterclayton/proto_default_on
Automatic merge from submit-queue

Enable protobuf compilation by default

Enables protobuf compilation, build verification checks, and generates all initial code.

kubectl is now 47M on OSX, build time from clean on a 2014 MBP (4 core) on Go 1.6 is ~150s.

@wojtek-t
2016-04-20 18:27:26 -07:00
k8s-merge-robot f3f3a685ab Merge pull request #24537 from mwielgus/fix-race-hpa
Automatic merge from submit-queue

Add locks in HPA test

Fixes #23361
2016-04-20 17:49:45 -07:00
Hongchao Deng 2bc022aad4 watcher test: print more info for debugging 2016-04-21 06:56:50 +08:00