Uploaded image for project: 'OpenShift Pod Autoscaling'
  1. OpenShift Pod Autoscaling
  2. PODAUTO-28

Upstream effort of adding E2E tests for in-place resource update

XMLWordPrintable

    • Icon: Story Story
    • Resolution: Done
    • Icon: Major Major
    • None
    • None
    • None

      The main change since we last worked on it was this commit: https://github.com/kubernetes/enhancements/commit/1bb48a9abf15f263fcb401faaba15371c1e7378c#diff-6b3cbf42a2a3f2625c86eee70c4e58dd81267b23528312ca71fefa61fb5d62ac
       
      Tim Hockin, Dawn and Vinay discussed this and agreed to the following key changes:

      • Move ResourcesAllocated from Spec.Container to Status.ContainerStatuses in Pod (ContainerStatus struct has this field now)
      • A new field named 'Resize' is added to PodStatus that summarizes the state ofrequested  pod resize.
      • Naming change for resize policies.
      • The persistent state of resources allocated to a Pod is maintained in a checkpoint file locally on the node.
         
        Vinay commits the E2E tests I had written earlier, along with some of his changes to the old PR. Vinay updates to my PR and was sitting uncommitted due to occasional flakes he didn't get a chance to dive deeper into. He has committed it now to the old (closed) PR branch - please see file: https://github.com/vinaykul/kubernetes/blob/af8cfe8f6d4192767673245c31797918823f7867/test/e2e/common/pod_resize.go 
         
        With the old PR, in order to run E2E tests for Inplace pod vertical scaling feature as below:
      1. Install kubetest. Please see https://github.com/kubernetes/test-infra/tree/master/kubetest#installation
      2. Enable featuregate by editing pkg/features/kube_features.go 
      3. -       InPlacePodVerticalScaling:                      {Default: false, PreRelease: featuregate.Alpha},

      +       InPlacePodVerticalScaling:                      {Default: true, PreRelease: featuregate.Beta},

      1. make clean && make all
      2. Start a local cluster: ./hack/local-up-cluster.sh
      3. In another terminal window, set the exports specified by local-up-cluster: 
      4. export KUBECONFIG=/var/run/kubernetes/admin.kubeconfig
      1. Run kubetest as follows:
      2. kubetest -test --test_args="-ginkgo.focus=PodInPlaceResize" --provider=local

      From an earlier feedback, I think we need to move this test from common to node directory.
       
      And to port this test, we need to update ResourcesAllocated fields to switch to Status instead of Spec (so that it builds with the API changes in my current PR https://github.com/kubernetes/kubernetes/pull/102884 ) and try running it (once my core implementation is ready and added to this PR).
       
      For the current PR, the originating branch is: https://github.com/vinaykul/kubernetes/tree/restart-free-pod-vertical-scaling
       
       

            chenw2020 Chen Wang
            chenw2020 Chen Wang
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: