1. 19 Oct, 2016 28 commits
    • Kubernetes Submit Queue's avatar
      Merge pull request #34765 from ivan4th/fix-more-typos · cd44cec5
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      Fix typos
      cd44cec5
    • Kubernetes Submit Queue's avatar
      Merge pull request #35071 from thockin/volume-mount-merge-key · 3fc8cff0
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      Change merge key for VolumeMount to mountPath
      
      Fixes #34800
      3fc8cff0
    • Kubernetes Submit Queue's avatar
      Merge pull request #35079 from dchen1107/test1 · 743e0689
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      Collect resource usage test with 0 pod for node benchmark.
      743e0689
    • Kubernetes Submit Queue's avatar
      Merge pull request #34819 from feiskyer/AppArmor · db2d8e0c
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      CRI: add docs for AppArmor and Seccomp
      
      This PR adds docs for AppArmor and Seccomp in CRI.
      
      cc/ @yujuhong @Random-Liu
      db2d8e0c
    • Kubernetes Submit Queue's avatar
      Merge pull request #34612 from jellonek/jell/fix_version_generation · 2e5303d2
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      build: Fix version generation.
      
      This PR provides update to version string generation procedure to handle additional case - working on branch delivered from release tag, instead of working on `-(alpha|beta).no` suffixed tag.
      
      Reason of it is that actually if someone would start working on branch forked from release tag (`v1.4.1` for example), will add some commits and then would try to build k8s/run conformance tests - will end up with broken version string in form similar to `v1.4.1.X+YYYY` where `X` is a dictance/number of commits from base tag and `YYYY` will be first 14 characters from commit hash.
      Such version - containing four dotted parts is rejected during conformance tests with error similar to:
      ```
      /go/src/k8s.io/kubernetes/_output/dockerized/go/src/k8s.io/kubernetes/test/e2e/kubectl.go:843
      Oct 11 12:38:33.726: Failed to get server version: Unable to parse server version "v1.4.1.5+somecommithash": Invalid character(s) found in patch number "1.5"
      /go/src/k8s.io/kubernetes/_output/dockerized/go/src/k8s.io/kubernetes/test/e2e/framework/util.go:413
      ```
      
      This PR provides a cure for this situation creating version string in form `v1.4.1-X+YYYY` which then should be readable for version validation checks. 
      
      Release note:
      ```release-note
      Fix version string generation for local version different from release and not based on `-alpha.no` or `-beta.no` suffixed tag.
      ```
      2e5303d2
    • Kubernetes Submit Queue's avatar
      Merge pull request #33352 from smarterclayton/unified_defaulters · 2ea4e1f0
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      Split conversion and defaulting
      
      Separate conversion and defaulting.   Defaulting occurs mixed with conversion today - change the server so that the `VersioningCodec` performs defaulting on the external type during decoding.  
      
      * Add a new method to `Scheme` - `func (*runtime.Scheme) Default(runtime.Object)` - that takes an object and performs defaulting.  
      * Call `Default` during decoding and at static initialization time
      * Use the new `defaulter-gen` to generate top level object defaulters (`v1.Pod`) at build time for any type that needs to perform defaulting.  
      * Add tests and alter the existing code to adapt as necessary
      * Fix a few bugs in conversions that depended on defaulting behavior
      
      ---
      
      Step 1 of decoupling conversion and defaulting. The generator will assist in creating top level defaulters that in a single method invoke all nested defaulters, preventing the need to recurse via reflection or conversion. These top level defaulters will be registered in the scheme and invoked instead of the nested recursion path. This will set the stage for a future generator, capable of creating defaulters from embedded struct tags on external types. However, we must gradually switch these over.
      
      The immediate goal here is to split defaulting and conversion so that the unsafe convertor can be used to maximum potential (we would be able to use direct memory conversion for any identical nested struct, even those that must be defaulted).
      
      The generator uses `k8s:defaulter-gen=TypeMeta` on most public packages to flag any top level type that has defaulters to get a `SetObjectDefaults_NAME` function created (types that don't have defaulters won't have functions).  This also creates a `RegisterDefaults` method that applies a default to an interface{} and returns true if the object was handled.  Existing defaults are left as is.
      
      Add a test to verify old and new path generate the same outcomes.  Defaulter will move to gengo before this is merged, and subsequent PRs will remove defaulting during conversion and have the VersioningCodec apply defaults.
      2ea4e1f0
    • Kubernetes Submit Queue's avatar
      Merge pull request #35047 from deads2k/controller-11-rs-flakes · 29af9853
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      fix more RS controller flakes
      
      I saw another flake:
      
      ```
      panic: Fail in goroutine after TestUpdatePods has completed
      /usr/local/go/src/runtime/panic.go:500 +0x1ae
      /go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/pkg/util/runtime/runtime.go:56 +0x17d
      /usr/local/go/src/runtime/panic.go:458 +0x271
      /usr/local/go/src/testing/testing.go:412 +0x182
      /usr/local/go/src/testing/testing.go:484 +0x95
      /go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/pkg/controller/replicaset/replica_set_test.go:619 +0x1d2
      /go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/pkg/controller/replicaset/replica_set.go:414 +0x191
      /go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/pkg/controller/replicaset/replica_set.go:403 +0x39
      /go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/pkg/controller/replicaset/replica_set.go:169 +0x42
      /go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/pkg/util/wait/wait.go:87 +0x70
      /go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/pkg/util/wait/wait.go:88 +0xbe
      /go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/pkg/util/wait/wait.go:49 +0x5b
      /go/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/pkg/controller/replicaset/replica_set_test.go:625 +0x369
      ```
      
      This resolves that by separating the listers from the watch like it used to be in this set of tests.  The tests were like this before the refactor.  I think they limit utility, but I'm not prepared to re-write them all.
      
      @kargakis
      29af9853
    • Kubernetes Submit Queue's avatar
      Merge pull request #34804 from YuPengZTE/devTypos · 2832efab
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      Clean up typos in links in README
      
      **What this PR does / why we need it**:
      Clean up the link in README for mysql-wordpress-pd and nfs
      Signed-off-by: 's avatarYuPengZTE <yu.peng36@zte.com.cn>
      2832efab
    • Kubernetes Submit Queue's avatar
      Merge pull request #35063 from slang800/patch-1 · c1b342b1
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      Change link to official Ceph Kubernetes docs
      c1b342b1
    • Kubernetes Submit Queue's avatar
      Merge pull request #34537 from AdoHe/get_info · 20841a5b
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      kubectl get print filter info use verbose
      
      add a quick fix #34469
      20841a5b
    • Kubernetes Submit Queue's avatar
      Merge pull request #35023 from k82cn/remove_empty_line · 103dc654
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      Removed empty line.
      103dc654
    • Clayton Coleman's avatar
      Run defaulting on the scheduler startup · 957c0955
      Clayton Coleman authored
      957c0955
    • Clayton Coleman's avatar
      Invoke init container defaulting in conversion · 3ee591d7
      Clayton Coleman authored
      Because annotations...
      
      Remove old references to DefaultingInterface in manual conversions.
      3ee591d7
    • Clayton Coleman's avatar
      Make defaulting part of versioning codec · 1694cfb7
      Clayton Coleman authored
      Most normal codec use should perform defaulting. DirectCodecs should not
      perform defaulting. Update the defaulting_test to fuzz the list of known
      defaulters. Use the new versioning.NewDefaultingCodec() method.
      1694cfb7
    • Clayton Coleman's avatar
      742fb698
    • Clayton Coleman's avatar
      Make defaulting optional during conversion generation · f294175d
      Clayton Coleman authored
      Set the Kubernetes default to "no defaulting"
      f294175d
    • Clayton Coleman's avatar
    • Clayton Coleman's avatar
      Register new defaulting functions · 89b3a0d8
      Clayton Coleman authored
      89b3a0d8
    • Clayton Coleman's avatar
      generated: Defaulters · 745690a2
      Clayton Coleman authored
      745690a2
    • Clayton Coleman's avatar
      Flag all packages as needing defaulters · 4324e393
      Clayton Coleman authored
      4324e393
    • Clayton Coleman's avatar
      Update makefile to generate defaulters · ca6fc3a6
      Clayton Coleman authored
      ca6fc3a6
    • Clayton Coleman's avatar
      Create a generator for defaulters · 1c49fc57
      Clayton Coleman authored
      Given an object that wishes to have a top level defaulter, traverse the
      object looking for nested fields that have defaulters and generate a
      single function for that type that invokes all defaulters. The function
      will have the name `SetObjectDefaults_NAME`.
      
      Types use `// +k8s:defaulter-gen=true` to indicate they wish a defaulter
      generated. If a function already exists with the desired name
      `SetObjectDefaults_NAME` then no generation will occur. At a package
      level, authors can bulk select the types to generate by setting the
      value of the comment to the name of a field - all objects with that
      field name without `// +k8s:defaulter-gen=false` defined on the type
      will get a defaulter.
      
      Because the defaulting behavior from conversions happens recursively,
      all defaulters are expected to be invoked. We call these defaulters
      "non-covering" (other defaulters may be invoked beneath them). The
      defaulters we generate, by comparison, are "covering" - no nested
      defaulters should be invoked. To distinguish between these two types, we
      introduce the `// +k8s:defaulter-gen=covers` comment on a defaulter
      function which will instruct the generator that the function should
      terminate recursion.
      
      This sets the stage for future defaulter generation from comments by
      subsuming our existing generators
      1c49fc57
    • Clayton Coleman's avatar
      5062406b
    • Clayton Coleman's avatar
      Move old defaulters to public functions · 0aa8da19
      Clayton Coleman authored
      Also make Deployment defaulting resilient to fuzzing
      0aa8da19
    • Clayton Coleman's avatar
      Add a new Default() method on Scheme · 68a9983e
      Clayton Coleman authored
      Allow defaulter functions to be registered with the scheme.
      68a9983e
    • Clayton Coleman's avatar
    • Dawn Chen's avatar
      6339b32a
    • Kubernetes Submit Queue's avatar
      Merge pull request #35060 from ixdy/get-kube-binaries-script · b844a072
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      Add option to get-kube-binaries.sh to download and extract tests
      
      A follow-on to #33701.
      
      My goal is to use `cluster/get-kube.sh` and `cluster/get-kube-binaries.sh` instead of the custom download/extraction logic in `e2e-runner.sh`. In addition to simplifying the logic, it'll also allow me to properly test removing the arch-specific binaries from `kubernetes.tar.gz`.
      
      Anyone on @kubernetes/test-infra-maintainers want to take a look?
      b844a072
  2. 18 Oct, 2016 12 commits
    • Kubernetes Submit Queue's avatar
      Merge pull request #34984 from mwielgus/configmap-fed-client · 6931fb18
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      ConfigMap in federated client
      
      cc: @quinton-hoole @nikhiljindal
      6931fb18
    • Kubernetes Submit Queue's avatar
      Merge pull request #34960 from sdminonne/serviceaccount_informer · a3148220
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      To add service account informer
      
      @deads2k  this PR adds ServiceAccount informer as discussed [here](https://github.com/openshift/origin/pull/11330#issuecomment-253216303)
      a3148220
    • Jeff Grafton's avatar
      Add option to get-kube-binaries.sh to download and extract tests · 2e503c1a
      Jeff Grafton authored
      Also fix an unset variable
      2e503c1a
    • Tim Hockin's avatar
      Change merge key for VolumeMount to mountPath · 837443d3
      Tim Hockin authored
      837443d3
    • Kubernetes Submit Queue's avatar
      Merge pull request #27784 from deads2k/catch-mutators · 4b7024ef
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      add optional mutation checks for shared informer cache
      
      We need to make sure that no one is mutating caches if they're using a shared informer.  It is important that whatever is tracking those changes gets the object *before* anyone else possibly could.
      
      This adds the ability to track the original objects in the cache and their current values.  Go doesn't have an exit hook or a way to say "wait for non-daemon go-funcs to complete before exit", so this runs a gofunc on a loop that can panic the entire process.  It's gated behind an env var.
      
      @derekwaynecarr did I get the right spots to make sure that e2e runs with this flag?
      @smarterclayton @kubernetes/rh-cluster-infra
      4b7024ef
    • Sean Lang's avatar
      Change link to official Ceph Kubernetes docs · 30abebd5
      Sean Lang authored
      @elsonrodriguez, @hunter, and @leseb have gotten Ceph to run almost entirely within Kubernetes. Also, the official Ceph Docker image is more likely to be kept updated.
      30abebd5
    • Kubernetes Submit Queue's avatar
      Merge pull request #34474 from liggitt/connection-info-refactor · f39e86c0
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      Remove static kubelet client, refactor ConnectionInfoGetter
      
      Follow up to https://github.com/kubernetes/kubernetes/pull/33718
      
      * Collapses the multi-valued return to a `ConnectionInfo` struct
      * Removes the "raw" connection info method and interface, since it was only used in a single non-test location (by the "real" connection info method)
      * Disentangles the node REST object from being a ConnectionInfoProvider itself by extracting an implementation of ConnectionInfoProvider that takes a node (using a provided NodeGetter) and determines ConnectionInfo
      * Plumbs the KubeletClientConfig to the point where we construct the helper object that combines the config and the node lookup. I anticipate adding a preference order for choosing an address type in https://github.com/kubernetes/kubernetes/pull/34259
      f39e86c0
    • Kubernetes Submit Queue's avatar
      Merge pull request #32628 from caesarxuchao/sync-gc · 97525c0c
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      [RFC] Add a proposal for synchronous garbage collection
      
      Tracking issue: #29891
      
      @lavalamp @kubernetes/sig-api-machinery @kubernetes/api-review-team
      97525c0c
    • Kubernetes Submit Queue's avatar
      Merge pull request #35038 from sjenning/nfs-nonblock-reader2 · 84aa5f69
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      kubelet: storage: don't hang kubelet on unresponsive nfs
      
      Fixes #31272 
      
      Currently, due to the nature of nfs, an unresponsive nfs volume in a pod can wedge the kubelet such that additional pods can not be run.
      
      The discussion thus far surrounding this issue was to wrap the `lstat`, the syscall that ends up hanging in uninterruptible sleep, in a goroutine and limiting the number of goroutines that hang to one per-pod per-volume.
      
      However, in my investigation, I found that the callsites that request a listing of the volumes from a particular volume plugin directory don't care anything about the properties provided by the `lstat` call.  They only care about whether or not a directory exists.
      
      Given that constraint, this PR just avoids the `lstat` call by using `Readdirnames()` instead of `ReadDir()` or `ReadDirNoExit()`
      
      ### More detail for reviewers
      Consider the pod mounted nfs volume at `/var/lib/kubelet/pods/881341b5-9551-11e6-af4c-fa163e815edd/volumes/kubernetes.io~nfs/myvol`.  The kubelet wedges because when we do a `ReadDir()` or `ReadDirNoExit()` it calls `syscall.Lstat` on `myvol` which requires communication with the nfs server.  If the nfs server is unreachable, this call hangs forever.
      
      However, for our code, we only care what about the names of files/directory contained in `kubernetes.io~nfs` directory, not any of the more detailed information the `Lstat` call provides.  Getting the names can be done with `Readdirnames()`, which doesn't need to involve the nfs server.
      
      @pmorie @eparis @ncdc @derekwaynecarr @saad-ali @thockin @vishh @kubernetes/rh-cluster-infra
      84aa5f69
    • Kubernetes Submit Queue's avatar
      Merge pull request #34944 from jellonek/mac_compatible_copy · 62cc4319
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      docs generation: Use macOS compatible copying method
      
      Replace option unknown for bsd version of `cp` used on macOS with compatible between systems replacement.
      
      Closes #34890
      
      ```release-note
      NONE
      ```
      62cc4319
    • Kubernetes Submit Queue's avatar
      Merge pull request #34946 from jellonek/macos_compatible_copying · a5da5c09
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      utils: Use macOS copatible copying method
      
      Same as in #34944, releated to #34890
      
      ```release-note
      NONE
      ```
      a5da5c09
    • Kubernetes Submit Queue's avatar
      Merge pull request #34939 from wojtek-t/throttle_retried_requests · b77e1344
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue
      
      Throttle retried requests in client
      
      Fix #34938
      b77e1344