This API is used to stop tasks in batches or delete real-time migration, real-time synchronization, and real-time DR tasks.
DELETE /v3/{project_id}/jobs/batch-jobs
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
project_id |
Yes |
String |
Project ID of a tenant in a region |
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
Content-Type |
Yes |
String |
The content type. The default value is application/json. |
X-Auth-Token |
Yes |
String |
User token obtained from IAM. |
X-Language |
No |
String |
Request language type Default value: en-us Values:
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
jobs |
Yes |
Array of DeleteJobReq objects |
List of requests for stopping or deleting tasks in batches. |
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
delete_type |
Yes |
String |
The value can be terminate, force_terminate, or delete. terminate indicates that the migration task is stopped, force_terminate indicates that the migration task is forcibly stopped, and delete indicates that the migration task is deleted. Values:
|
job_id |
Yes |
String |
Task ID. |
Status code: 202
Parameter |
Type |
Description |
|---|---|---|
results |
Array of DeleteJobResp objects |
Response body set for stopping or deleting tasks in batches. |
count |
Integer |
Total number. |
Parameter |
Type |
Description |
|---|---|---|
id |
String |
Task ID. |
status |
String |
Status Values:
|
error_code |
String |
Error code, which is optional and indicates the returned information about the failure status. |
error_msg |
String |
Error message, which is optional and indicates the returned information about the failure status. |
https://{EndPoint}/v3/054ba152d480d55b2f5dc0069e7ddef0/jobs/batch-jobs
{
"jobs" : [ {
"delete_type" : "terminate",
"job_id" : "4c6ac8c0-2f51-426a-97b2-cb2c668jb201"
}, {
"delete_type" : "terminate",
"job_id" : "6211d20d-0006-41da-836e-db3301ajb20b"
} ]
}
https://{EndPoint}/v3/054ba152d480d55b2f5dc0069e7ddef0/jobs/batch-jobs
{
"jobs" : [ {
"delete_type" : "delete",
"job_id" : "140b5236-88ad-43c8-811c-1268453jb101"
} ]
}
Status code: 202
Accepted
{
"count" : 2,
"results" : [ {
"id" : "4c6ac8c0-2f51-426a-97b2-cb2c668jb201",
"status" : "success"
}, {
"id" : "6211d20d-0006-41da-836e-db3301ajb20b",
"status" : "failed",
"error_code" : "DRS.M01504",
"error_msg" : "Another operation is being performed on the migration task or the migration task is abnormal. Try again later."
} ]
}
{
"count" : 1,
"results" : [ {
"id" : "140b5236-88ad-43c8-811c-1268453jb101",
"status" : "success"
} ]
}
Status Code |
Description |
|---|---|
202 |
Accepted |
400 |
Bad Request |
For details, see Error Code.