Details

    Description

      For preemption, we need to watch for changes to PriorityClass objects in Kubernetes in the admission controller / shim. This will be used to update pods with Yunikorn-specific annotations from an associated PriorityClass. This should be done in the admission controller, with a fallback to the scheduler if no annotation was present.

       

      The following annotation can be present either on a pod, or a priority class referenced by a pod:

      • yunikorn.apache.org/allow-preemption: "true" | "false"
        • Whether this pod should be eligible for preemption (default "true"). If set to "false", this pod will be will be avoided for preemption, and will only be considered if no other candidates are possible.

      If the annotation exists and is set to a valid value, it will be preserved by the admission controller.

      If the annotation does not exist or is invalid, but a priority class is set, the value from the priority class will be used.

      If the annotation does not exist in either location, the admission controller will add it with the default value of "true". This is to avoid ambiguity in the scheduler. The scheduler will use this value, and if not present, also query any associated priority class. This allows the admission controller to remain an optional component, and still be able to make use of this functionality. In this mode, recovery could potentially result in different preemption behavior, as the priority class may have changed between pod submission and recovery. Using the admission controller avoids this.

       

      Attachments

        Issue Links

          Activity

            People

              ccondit Craig Condit
              ccondit Craig Condit
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: