Stopping a Job

Function

This API is used to stop a running job.

URI

  • URI format

    POST /v1.0/{project_id}/job/{job_id}/stop

  • Parameter description
    Table 1 URI parameter description

    Parameter

    Type

    Mandatory

    Description

    project_id

    Route parameter

    Yes

    Project ID. For details about how to obtain the project ID, see Obtaining a Project ID.

    job_id

    Route parameter

    Yes

    Job ID.

    triggerSavePoint

    Query parameter

    No

    Whether to create a savepoint for a job to store the job status information before stopping it. The data type is Boolean.

    • If this parameter is set to true, a savepoint is created.
    • If this parameter is set to false, no savepoint is created. The default value is false.

Request

None

Response

  • Example response
    {
    "message_id": "CS.10001",
    "message": "Message content",
      "current_time": 1533686888000
    }
  • Parameter description
    Table 2 Response parameters

    Parameter

    Mandatory

    Type

    Description

    message_id

    No

    String

    Message type ID.

    message

    No

    String

    Message content.

    current_time

    No

    Int

    Current time, expressed by milliseconds.

Status Code

Table 3 describes the status code.

Table 3 Status code

Status Code

Description

200

The request of stopping a job is sent successfully.

400

The input parameters are invalid.

Error Code

For details, see Error Codes.