All Products
Search
Document Center

Container Compute Service:Create a Job workload

Last Updated:Oct 28, 2026

A Job runs short-lived, one-off batch tasks and ensures that one or more pods in the batch complete successfully. Job workloads can be created in the Alibaba Cloud Container Compute Service (ACS) console.

Background information

Jobs are classified into the following types based on the .spec.completions and .spec.parallelism settings:

.spec.completions is the number of pods that must complete successfully. Default value: 1. .spec.parallelism is the maximum number of replicas that a Job can run in parallel. Default value: 1.

Job type

completions

parallelism

Example

Behavior

One-off Job

1

1

Database migration

Runs one pod until it completes successfully.

Job with a fixed completion count

2+

1

Pods that process a work queue

Pods run one after another until the number of pods that complete successfully reaches the value of completions.

Parallel Job with a work queue

1

2+

Multiple pods that process a work queue at the same time, with no required success count

Multiple pods run in parallel until one pod completes successfully.

Parallel Job with a fixed completion count

2+

2+

Multiple pods that process a work queue at the same time, with a required success count

Multiple pods run in parallel until the number of pods that complete successfully reaches the value of completions.

Procedure

Step 1: Configure basic application information

  1. Log on to the ACS console. In the left navigation pane, click Clusters.

  2. On the Clusters page, click the name of the target cluster, or click Details in the Actions column.

  3. In the left navigation pane of the cluster details page, choose Workloads > Jobs.

  4. On the Jobs page, click Create from Image.

  5. On the Basic Information wizard page, configure the basic information of the application.

    Parameter

    Description

    Application Name

    Enter a name for the application.

    Type

    Select Job.

    Label

    Add a label to identify the application.

    Annotations

    Add an annotation to the application.

    Instance Type

    Select a compute type. For details about compute types, see Overview of ACS pod instances.

    QoS Type

    Select a Quality of Service (QoS) class.

    Correspondence Between Computing Type and Computing Power Quality

    Compute type (label)

    Supported computing power quality classes (labels)

    General-purpose (general-purpose)

    Default (default), BestEffort (best-effort)

    Performance-optimized (performance)

    Default (default), BestEffort (best-effort)

    GPU type (gpu)

    Default (default), BestEffort (best-effort)

    High-performance network GPU (gpu-hpn)

    Default (default)

    For more information, see QoS class definitions.

  6. After you configure the basic information, click Next.

Step 2: Configure containers

On the Container wizard page, configure the container image, resources, ports, environment variables, lifecycle, volumes, and logging.

Note

To add multiple containers to the pod, click Add Container next to the Container 1 tab.

Step 3: Complete advanced configuration

  1. In the Job Settings section, configure the Job parameters.

    Parameter

    Description

    Completions

    Corresponds to completions. Specifies the number of pods that must complete successfully. Default value: 1.

    Parallelism

    Corresponds to parallelism. Specifies the maximum number of pods that the Job can run concurrently. Default value: 1.

    Timeout

    Corresponds to activeDeadlineSeconds. Specifies how long the Job is allowed to run. Unit: seconds. Valid values: positive integers. If you do not set this parameter, the Job runs without a deadline. If the Job does not finish within this period, the system attempts to stop it.

    BackoffLimit

    The number of attempts to recreate a pod after it fails to run. Default value: 6. Each retry after a failure is delayed, and the delay grows exponentially up to a maximum of 6 minutes.

    Restart

    Only Never (Never) and On Failure (OnFailure) are supported.

    Important

    If the timeout is shorter than the time that the Job pods need, the Job ends before the pods complete and the work in progress is lost. If the timeout is longer than needed, a pod that hangs keeps consuming billable compute resources until the deadline expires.

  2. (Optional) In the Labels and Annotations section, click Add to set labels and annotations for the pod.

  3. Click Create.

Step 4: View application information

After the application is created, the completion page is displayed by default. Click View Details to go to the details page of the Job.

Information about the Job is also available on the Jobs page. Click the name of the target Job, or in the Actions column, click Details to go to the application details page.