Use Knative serving to automatically manage the infrastructure needed to host software on Google Kubernetes Engine (GKE). To manage your applications, Knative serving uses an organizational structure called a resource model. This resource model consists of three main parts: Services, Revisions, and Container Instances.
The following diagram illustrates these components and their interactions: a Google Cloud project contains two Knative serving services, Service A and Service B, each with several revisions. Service A is processing requests with multiple running container instances, while Service B is idle.
Knative serving services
The service is the main resource of Knative serving. Each service is located in a specific GKE cluster namespace.
A given Google Cloud project can run many services in different regions or GKE clusters.
Each service exposes a unique endpoint and automatically scales the underlying infrastructure to handle incoming requests.
Knative serving revisions
Each deployment to a service creates a revision. A revision consists of a specific container image, along with environment settings such as environment variables, memory limits, or concurrency value.
Revisions are immutable: once a revision has been created, it cannot be modified. For example, when you deploy a container image to a new Knative serving service, the first revision is created. If you then deploy a different container image to that same service, a second revision is created. If you subsequently set an environment variable, a third revision is created. Each subsequent configuration change creates a new revision.
Requests are automatically routed as soon as possible to the latest healthy service revision. You can split traffic between different revisions as needed.
Knative serving container instances
Each revision receiving requests is automatically scaled to the number of container instances needed to handle all these requests. Note that a container instance can receive many requests at the same time. With the concurrency setting, you can set the maximum number of requests that can be sent in parallel to a given container instance.