Uploaded image for project: 'Knative Serving'
  1. Knative Serving
  2. SRVKS-1113

setting KnativeServing .spec.workloads[].replicas does work for HPA-enabled components (activator and webhook)

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Undefined Undefined
    • 1.31.0
    • 1.29.0, 1.30.0
    • None
    • None
    • False
    • Hide

      None

      Show
      None
    • False

      KnativeServing components that are scaled by HPA (webhook and activator) cannot be scaled via `workloads`

        workloads:
        - name: activator
          replicas: 6
        - name: webhook
          replicas: 4
      

      will scale the deployments, but that will be overridden by the HPA, leading to pods being scaled up/down, as the HPA battles with the operator over the deployment replicas

       oc get hpa
      NAME        REFERENCE              TARGETS   MINPODS   MAXPODS   REPLICAS   AGE
      activator   Deployment/activator   0%/100%   1         20        6          24m
      webhook     Deployment/webhook     1%/100%   1         5         4          24m
      

      Instead of updating the Deployment replicas, the operator should instead modify the minPods for the HPA for the components with HPA.

      (compared to setting via .high-availability.replicas

        high-availability:
          replicas: 4
      

      which does update the HPA minScale

      oc get hpa
      NAME        REFERENCE              TARGETS   MINPODS   MAXPODS   REPLICAS   AGE
      activator   Deployment/activator   0%/100%   4         23        4          28m
      webhook     Deployment/webhook     5%/100%   4         8         4          28m
      

              rh-ee-rlehmann Reto Lehmann (Inactive)
              maschmid@redhat.com Marek Schmidt
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: