Skip to content

Support Stop/Resume of KNative Services #16489

@cl-gavan

Description

@cl-gavan

/area API
/area autoscale
/area networking
/kind spec

Describe the feature

We (Cloudera) are building an Application Serving platform on top of KNative, and our customers have asked for a feature to stop Applications at the end of their work day, and be able to resume the same Applications the next work day to save on compute costs overnight. While we could build this into our own platform directly, we think we might bring value into the KNative community by contributing this feature upstream.

The feature would work similarly to stop/resume of endpoints in KServe:

  1. We propose adding a new annotation: "serving.knative.dev/stopped". When this is set to true on a KNative Service, KNative would stop routing traffic to that service, and allow it to scale down to 0. Any traffic to this service would return an error. (e.g., http.StatusServiceUnavailable)
  2. A new "stopped" condition would need to be added to revision status.
  3. Autoscaler would check for the new annotation and skip scaling decisions entirely if it is set to true: Don't scale up from zero, don't process metrics.
  4. Networking/Route Controller would exclude stopped revisions from routing decisions. Don't include them in traffic splits even if they have traffic assigned.

We are willing to invest engineering effort into building and maintaining this feature, and would primarily need help with KNative architectural guidance and code reviews.

Also, as a side note, KServe has two deployment modes, and serverless mode (KNative mode) does not have the stop/resume endpoints feature. By adding this feature to KNative, we would also be adding value to KServe downstream as well.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/APIAPI objects and controllersarea/autoscalearea/networkingkind/featureWell-understood/specified features, ready for coding.kind/specDiscussion of how a feature should be exposed to customers.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions