更新时间:2024-05-27 GMT+08:00

查询租户任务列表

功能介绍

查询租户任务列表,可以根据引擎类型,网络类型,任务状态,任务名称,任务ID进行查询。

调试

您可以在API Explorer中调试该接口,支持自动认证鉴权。API Explorer可以自动生成SDK代码示例,并提供SDK代码示例调试功能。

URI

POST /v3/{project_id}/jobs

表1 路径参数

参数

是否必选

参数类型

描述

project_id

String

租户在某一Region下的Project ID。

获取方法请参见获取项目ID

请求参数

表2 请求Header参数

参数

是否必选

参数类型

描述

Content-Type

String

指定类型为application/json。

缺省值:application/json

X-Auth-Token

String

从IAM服务获取的用户Token。

X-Language

String

请求语言类型。

缺省值:en-us

取值:

  • en-us
  • zh-cn
表3 请求Body参数

参数

是否必选

参数类型

描述

cur_page

Integer

当前页,填0获取全部item。当per_page填0时,cur_page只能填0或者1。

缺省值:1

per_page

Integer

每页记录数。填0时,cur_page只能填0或者1。

  • 默认值:10
  • 最小值:0
  • 最大值:100

db_use_type

String

迁移场景。migration:实时迁移;sync:实时同步;cloudDataGuard:实时灾备。

取值:

  • migration
  • sync
  • cloudDataGuard

engine_type

String

DRS任务引擎类型。

缺省值:mysql

取值:

  • mysql:MySQL到MySQL迁移,MySQL到MySQL同步
  • mongodb:MongoDB到DDS迁移
  • cloudDataGuard-mysql:MySQL到MySQL灾备
  • gaussdbv5GaussDB同步
  • mysql-to-kafka:MySQL到Kafka同步
  • taurus-to-kafka:GaussDB(for MySQL)到Kafka同步
  • gaussdbv5ha-to-kafkaGaussDB主备版到Kafka同步
  • postgresql:PostgreSQL到PostgreSQL同步

详细取值可参考引擎类型说明

enterprise_project_id

String

企业项目,不传值的话,设置为null,不能设置为空字符串。当企业项目开关打开时,可以传值。

name

String

Name或ID。支持传入多个任务ID,逗号分隔,最多100个。

net_type

String

网络类型。取值:

  • vpn
  • vpc
  • eip

service_name

String

服务名称。

status

String

任务状态。

  • CREATING:创建中。
  • CREATE_FAILED:创建失败。
  • CONFIGURATION:配置中。
  • STARTJOBING:启动中。
  • WAITING_FOR_START:等待启动中。
  • START_JOB_FAILED:启动失败。
  • PAUSING:已暂停。
  • FULL_TRANSFER_STARTED:全量开始,灾备场景下为初始化。
  • FULL_TRANSFER_FAILED:全量失败,灾备场景下为初始化失败。
  • FULL_TRANSFER_COMPLETE:全量完成,灾备场景下为初始化完成。
  • INCRE_TRANSFER_STARTED:增量开始,灾备场景下为灾备中。
  • INCRE_TRANSFER_FAILED:增量失败,灾备场景下为灾备异常。
  • RELEASE_RESOURCE_STARTED:结束任务中。
  • RELEASE_RESOURCE_FAILED:结束任务失败。
  • RELEASE_RESOURCE_COMPLETE:已结束。
  • REBUILD_NODE_STARTED:故障恢复中。
  • REBUILD_NODE_FAILED:故障恢复失败。
  • CHANGE_JOB_STARTED:任务变更中。
  • CHANGE_JOB_FAILED:任务变更失败。
  • DELETED:已删除。
  • CHILD_TRANSFER_STARTING:再编辑子任务启动中。
  • CHILD_TRANSFER_STARTED:再编辑子任务迁移中。
  • CHILD_TRANSFER_COMPLETE:再编辑子任务迁移完成。
  • CHILD_TRANSFER_FAILED:再编辑子任务迁移失败。
  • RELEASE_CHILD_TRANSFER_STARTED:再编辑子任务结束中。
  • RELEASE_CHILD_TRANSFER_COMPLETE:再编辑子任务已结束。
  • NODE_UPGRADE_START:升级开始。
  • NODE_UPGRADE_COMPLETE:升级完成。
  • NODE_UPGRADE_FAILED:升级失败。

枚举值:

  • CREATING
  • CREATE_FAILED
  • CONFIGURATION
  • STARTJOBING
  • WAITING_FOR_START
  • START_JOB_FAILED
  • PAUSING
  • FULL_TRANSFER_STARTED
  • FULL_TRANSFER_FAILED
  • FULL_TRANSFER_COMPLETE
  • INCRE_TRANSFER_STARTED
  • INCRE_TRANSFER_FAILED
  • RELEASE_RESOURCE_STARTED
  • RELEASE_RESOURCE_FAILED
  • RELEASE_RESOURCE_COMPLETE
  • REBUILD_NODE_STARTED
  • REBUILD_NODE_FAILED
  • CHANGE_JOB_STARTED
  • CHANGE_JOB_FAILED
  • DELETED
  • CHILD_TRANSFER_STARTING
  • CHILD_TRANSFER_STARTED
  • CHILD_TRANSFER_COMPLETE
  • CHILD_TRANSFER_FAILED
  • RELEASE_CHILD_TRANSFER_STARTED
  • RELEASE_CHILD_TRANSFER_COMPLETE
  • NODE_UPGRADE_START
  • NODE_UPGRADE_COMPLETE
  • NODE_UPGRADE_FAILED

tags

Map<String,String>

标签。

详情请参见表7

instance_ids

Array of strings

数据库实例ID列表,缺省值:null,表示不使用数据库实例ID过滤。

instance_ip

String

DRS绑定的数据库实例IP,缺省值:"",表示不使用DRS绑定数据库IP过滤。

响应参数

状态码: 200

表4 响应Body参数

参数

参数类型

描述

total_record

Integer

任务总数。

jobs

Array of objects

任务信息列表。

详情请参见表5

表5 jobs字段数据结构说明

参数

参数类型

描述

id

String

任务ID。

name

String

任务名称。

status

String

任务状态。

  • CREATING:创建中。
  • CREATE_FAILED:创建失败。
  • CONFIGURATION:配置中。
  • STARTJOBING:启动中。
  • WAITING_FOR_START:等待启动中。
  • START_JOB_FAILED:启动失败。
  • PAUSING:已暂停。
  • FULL_TRANSFER_STARTED:全量开始,灾备场景下为初始化。
  • FULL_TRANSFER_FAILED:全量失败,灾备场景下为初始化失败。
  • FULL_TRANSFER_COMPLETE:全量完成,灾备场景下为初始化完成。
  • INCRE_TRANSFER_STARTED:增量开始,灾备场景下为灾备中。
  • INCRE_TRANSFER_FAILED:增量失败,灾备场景下为灾备异常。
  • RELEASE_RESOURCE_STARTED:结束任务中。
  • RELEASE_RESOURCE_FAILED:结束任务失败。
  • RELEASE_RESOURCE_COMPLETE:已结束。
  • REBUILD_NODE_STARTED:故障恢复中。
  • REBUILD_NODE_FAILED:故障恢复失败。
  • CHANGE_JOB_STARTED:任务变更中。
  • CHANGE_JOB_FAILED:任务变更失败。
  • DELETED:已删除。
  • CHILD_TRANSFER_STARTING:再编辑子任务启动中。
  • CHILD_TRANSFER_STARTED:再编辑子任务迁移中。
  • CHILD_TRANSFER_COMPLETE:再编辑子任务迁移完成。
  • CHILD_TRANSFER_FAILED:再编辑子任务迁移失败。
  • RELEASE_CHILD_TRANSFER_STARTED:再编辑子任务结束中。
  • RELEASE_CHILD_TRANSFER_COMPLETE:再编辑子任务已结束。
  • NODE_UPGRADE_START:升级开始。
  • NODE_UPGRADE_COMPLETE:升级完成。
  • NODE_UPGRADE_FAILED:升级失败。

枚举值:

  • CREATING
  • CREATE_FAILED
  • CONFIGURATION
  • STARTJOBING
  • WAITING_FOR_START
  • START_JOB_FAILED
  • PAUSING
  • FULL_TRANSFER_STARTED
  • FULL_TRANSFER_FAILED
  • FULL_TRANSFER_COMPLETE
  • INCRE_TRANSFER_STARTED
  • INCRE_TRANSFER_FAILED
  • RELEASE_RESOURCE_STARTED
  • RELEASE_RESOURCE_FAILED
  • RELEASE_RESOURCE_COMPLETE
  • REBUILD_NODE_STARTED
  • REBUILD_NODE_FAILED
  • CHANGE_JOB_STARTED
  • CHANGE_JOB_FAILED
  • DELETED
  • CHILD_TRANSFER_STARTING
  • CHILD_TRANSFER_STARTED
  • CHILD_TRANSFER_COMPLETE
  • CHILD_TRANSFER_FAILED
  • RELEASE_CHILD_TRANSFER_STARTED
  • RELEASE_CHILD_TRANSFER_COMPLETE
  • NODE_UPGRADE_START
  • NODE_UPGRADE_COMPLETE
  • NODE_UPGRADE_FAILED

description

String

任务描述。

create_time

String

任务创建时间。

engine_type

String

DRS任务引擎类型。取值:

  • mysql:MySQL到MySQL迁移,MySQL到MySQL同步
  • mongodb:MongoDB到DDS迁移
  • cloudDataGuard-mysql:MySQL到MySQL灾备
  • gaussdbv5GaussDB同步
  • mysql-to-kafka:MySQL到Kafka同步
  • taurus-to-kafka:GaussDB(for MySQL)到Kafka同步
  • gaussdbv5ha-to-kafkaGaussDB主备版到Kafka同步
  • postgresql:PostgreSQL到PostgreSQL同步

详细取值可参考引擎类型说明

net_type

String

网络类型。取值:

  • vpn
  • vpc
  • eip

billing_tag

Boolean

计费字段。

job_direction

String

任务方向。取值:

  • up:入云,灾备场景时对应本云为备
  • down:出云,灾备场景时对应本云为主。
  • non-dbs:自建。

db_use_type

String

任务场景。取值:

  • migration:实时迁移。
  • sync:实时同步。
  • cloudDataGuard:实时灾备。

task_type

String

任务模式。取值:

  • FULL_TRANS :全量。
  • FULL_INCR_TRANS:全量+增量。
  • INCR_TRANS:增量。

children

Array of objects

子任务信息体。

详情请参见表6

node_newFramework

Boolean

是否新框架。

job_action

Object

任务操作命令矩阵。

详情请参见表7

表6 children字段数据结构说明

参数

参数类型

描述

billing_tag

Boolean

计费字段。

create_time

String

任务创建时间。

db_use_type

String

复制场景。取值:

  • migration:实时迁移。
  • sync:实时同步。
  • cloudDataGuard:实时灾备。

description

String

任务描述。

engine_type

String

DRS任务引擎类型。取值:

  • mysql:MySQL到MySQL迁移,MySQL到MySQL同步
  • mongodb:MongoDB到DDS迁移
  • cloudDataGuard-mysql:MySQL到MySQL灾备
  • gaussdbv5GaussDB同步
  • mysql-to-kafka:MySQL到Kafka同步
  • taurus-to-kafka:GaussDB(for MySQL)到Kafka同步
  • gaussdbv5ha-to-kafkaGaussDB主备版到Kafka同步
  • postgresql:PostgreSQL到PostgreSQL同步

详细取值可参考引擎类型说明

error_msg

String

任务失败原因。

id

String

任务ID。

job_direction

String

迁移方向。取值:

  • up:入云,灾备场景时对应本云为备
  • down:出云,灾备场景时对应本云为主。
  • non-dbs:自建。

name

String

任务名称。

net_type

String

网络类型。取值:

  • vpc
  • vpn
  • eip

node_newFramework

Boolean

新框架。

status

String

任务状态。

  • CREATING:创建中。
  • CREATE_FAILED:创建失败。
  • CONFIGURATION:配置中。
  • STARTJOBING:启动中。
  • WAITING_FOR_START:等待启动中。
  • START_JOB_FAILED:启动失败。
  • PAUSING:已暂停。
  • FULL_TRANSFER_STARTED:全量开始,灾备场景下为初始化。
  • FULL_TRANSFER_FAILED:全量失败,灾备场景下为初始化失败。
  • FULL_TRANSFER_COMPLETE:全量完成,灾备场景下为初始化完成。
  • INCRE_TRANSFER_STARTED:增量开始,灾备场景下为灾备中。
  • INCRE_TRANSFER_FAILED:增量失败,灾备场景下为灾备异常。
  • RELEASE_RESOURCE_STARTED:结束任务中。
  • RELEASE_RESOURCE_FAILED:结束任务失败。
  • RELEASE_RESOURCE_COMPLETE:已结束。
  • REBUILD_NODE_STARTED:故障恢复中。
  • REBUILD_NODE_FAILED:故障恢复失败。
  • CHANGE_JOB_STARTED:任务变更中。
  • CHANGE_JOB_FAILED:任务变更失败。
  • DELETED:已删除。
  • CHILD_TRANSFER_STARTING:再编辑子任务启动中。
  • CHILD_TRANSFER_STARTED:再编辑子任务迁移中。
  • CHILD_TRANSFER_COMPLETE:再编辑子任务迁移完成。
  • CHILD_TRANSFER_FAILED:再编辑子任务迁移失败。
  • RELEASE_CHILD_TRANSFER_STARTED:再编辑子任务结束中。
  • RELEASE_CHILD_TRANSFER_COMPLETE:再编辑子任务已结束。
  • NODE_UPGRADE_START:升级开始。
  • NODE_UPGRADE_COMPLETE:升级完成。
  • NODE_UPGRADE_FAILED:升级失败。

枚举值:

  • CREATING
  • CREATE_FAILED
  • CONFIGURATION
  • STARTJOBING
  • WAITING_FOR_START
  • START_JOB_FAILED
  • PAUSING
  • FULL_TRANSFER_STARTED
  • FULL_TRANSFER_FAILED
  • FULL_TRANSFER_COMPLETE
  • INCRE_TRANSFER_STARTED
  • INCRE_TRANSFER_FAILED
  • RELEASE_RESOURCE_STARTED
  • RELEASE_RESOURCE_FAILED
  • RELEASE_RESOURCE_COMPLETE
  • REBUILD_NODE_STARTED
  • REBUILD_NODE_FAILED
  • CHANGE_JOB_STARTED
  • CHANGE_JOB_FAILED
  • DELETED
  • CHILD_TRANSFER_STARTING
  • CHILD_TRANSFER_STARTED
  • CHILD_TRANSFER_COMPLETE
  • CHILD_TRANSFER_FAILED
  • RELEASE_CHILD_TRANSFER_STARTED
  • RELEASE_CHILD_TRANSFER_COMPLETE
  • NODE_UPGRADE_START
  • NODE_UPGRADE_COMPLETE
  • NODE_UPGRADE_FAILED

task_type

String

任务模式。取值:

  • FULL_TRANS :全量。
  • FULL_INCR_TRANS:全量+增量。
  • INCR_TRANS:增量。

job_action

Object

任务操作命令矩阵。

详情请参见表7

表7 job_action字段数据结构说明

参数

参数类型

描述

available_actions

Array of strings

任务可操作命令集合。

取值:

  • CREATE:创建任务
  • CHOOSE_OBJECT:选择对象
  • PRE_CHECK:预检查
  • CHANGE_MODE:修改任务模式
  • FREE_RESOURCE:释放资源
  • MODIFY_DB_CONFIG:修改数据库配置
  • RESET_DB_PWD:重置数据库密码(源库、目标库)
  • MODIFY_CONFIGURATION:修改任务配置
  • PAUSE:暂停任务
  • START:启动任务
  • CHANGE:修改任务
  • RETRY:重试任务
  • RESET:重置任务
  • DELETE:删除任务
  • QUERY_PRE_CHECK:预检查
  • SWITCH_OVER:容灾倒换
  • START_INCR:CASSANDRA启动增量任务
  • MODIFY_TASK_NUMBER:CASSANDRA修改线程数配置
  • CONTINUE_JOB:oracle-GaussDB分布式:启动失败或者停止的任务
  • STOP_JOB:oracle-GaussDB分布式:停止任务
  • CONTINUE_CAPTURE:oracle-GaussDB分布式:启动抓取
  • STOP_CAPTURE:oracle-GaussDB分布式:停止抓取
  • CONTINUE_APPLY:oracle-GaussDB分布式:启动回放
  • STOP_APPLY:oracle-GaussDB分布式:停止回放
  • PAY_ORDER:包年包月支付订单
  • UNSUBSCRIBE:包年包月退订
  • TO_PERIOD:转包周期
  • TO_RENEW:包周期续费
  • ORDER_INFO:订单详情
  • CHANGE_FLAVOR:规格变更
  • CLONE:克隆任务

unavailable_actions

Array of strings

任务不可操作命令集合。

取值:

  • CREATE:创建任务
  • CHOOSE_OBJECT:选择对象
  • PRE_CHECK:预检查
  • CHANGE_MODE:修改任务模式
  • FREE_RESOURCE:释放资源
  • MODIFY_DB_CONFIG:修改数据库配置
  • RESET_DB_PWD:重置数据库密码(源库、目标库)
  • MODIFY_CONFIGURATION:修改任务配置
  • PAUSE:暂停任务
  • START:启动任务
  • CHANGE:修改任务
  • RETRY:重试任务
  • RESET:重置任务
  • DELETE:删除任务
  • QUERY_PRE_CHECK:预检查
  • SWITCH_OVER:容灾倒换
  • START_INCR:CASSANDRA启动增量任务
  • MODIFY_TASK_NUMBER:CASSANDRA修改线程数配置
  • CONTINUE_JOB:oracle-GaussDB分布式:启动失败或者停止的任务
  • STOP_JOB:oracle-GaussDB分布式:停止任务
  • CONTINUE_CAPTURE:oracle-GaussDB分布式:启动抓取
  • STOP_CAPTURE:oracle-GaussDB分布式:停止抓取
  • CONTINUE_APPLY:oracle-GaussDB分布式:启动回放
  • STOP_APPLY:oracle-GaussDB分布式:停止回放
  • PAY_ORDER:包年包月支付订单
  • UNSUBSCRIBE:包年包月退订
  • TO_PERIOD:转包周期
  • TO_RENEW:包周期续费
  • ORDER_INFO:订单详情
  • CHANGE_FLAVOR:规格变更
  • CLONE:克隆任务

current_action

String

当前操作。取值:

  • SWITCH_OVER:灾备倒换中
  • STOP_JOB:任务暂停中

请求示例

  • 查询实时同步任务列表示例:
    https://{endpoint}/v3/054ba152d480d55b2f5dc0069e7ddef0/jobs
    
    {
      "cur_page" : 1,
      "db_use_type" : "sync",
      "engine_type" : "",
      "name" : "",
      "net_type" : "",
      "per_page" : 5,
      "status" : ""
    }
  • 查询实时迁移任务列表示例:
    https://{endpoint}/v3/054ba152d480d55b2f5dc0069e7ddef0/jobs
    
    {
      "cur_page" : 1,
      "db_use_type" : "migration",
      "engine_type" : "",
      "name" : "",
      "net_type" : "",
      "per_page" : 5,
      "status" : ""
    }
  • 通过数据库实例ID,查询实时同步任务列表示例:
    https://{endpoint}/v3/054ba152d480d55b2f5dc0069e7ddef0/jobs 
      
     { 
       "cur_page" : 1, 
       "db_use_type" : "sync", 
       "engine_type" : "", 
       "enterprise_project_id" : "", 
       "name" : "", 
       "net_type" : "", 
       "per_page" : 5, 
       "instance_ids" : [ "id1", "id2" ], 
       "status" : "" 
     }
  • 通过数据库实例IP,查询实时同步任务列表示例:
    https://{endpoint}/v3/054ba152d480d55b2f5dc0069e7ddef0/jobs 
      
     { 
       "cur_page" : 1, 
       "db_use_type" : "sync", 
       "engine_type" : "", 
       "enterprise_project_id" : "", 
       "name" : "", 
       "net_type" : "", 
       "per_page" : 5, 
       "instance_ip" : "127.0.0.1", 
       "status" : "" 
     }
  • 查询实时同步任务列表多个任务ID示例:
    https://{endpoint}/v3/054ba152d480d55b2f5dc0069e7ddef0/jobs 
      
    {
      "cur_page": 1,
      "db_use_type": "sync",
      "engine_type": "",
      "name": "bee869bc-15c0-4b3b-a34b-bf0d5efjb201,c2a61a77-6e55-4cd8-8be1-a562cc6jb201",
      "net_type": "",
      "per_page": 100,
      "status": ""
    }

响应示例

状态码: 200

OK

  • 查询实时迁移任务列表响应示例 :
    {
      "jobs" : [ {
        "id" : "24834eb6-be30-464e-a299-f7aa730jb101",
        "name" : "DRS-3999-lws",
        "status" : "INCRE_TRANSFER_FAILED",
        "description" : "",
        "create_time" : "2020-12-21 10:57:49",
        "error_msg" : "service LOGMANAGER failed, cause by: Unable to connect to DBMS: url=jdbc:mysql://172.22.74.56:3306?useUnicode=true&allowLoadLocalInfile=false&characterEncoding=UTF-8&connectTimeout=5000&useSSL=false&allowPublicKeyRetrieval=true&verifyServerCertificate=false&serverTimezone=UTC user=root",
        "engine_type" : "mysql",
        "net_type" : "eip",
        "billing_tag" : false,
        "job_direction" : "up",
        "db_use_type" : "migration",
        "task_type" : "FULL_INCR_TRANS",
        "node_newFramework" : false
        "job_action":{
            "available_actions": [
                "CREATE",
                "CHOOSE_OBJECT",
                "PRE_CHECK",
                "CHANGE_MODE",
                "FREE_RESOURCE",
                "MODIFY_DB_CONFIG",
                "RESET_DB_PWD",
                "MODIFY_CONFIGURATION",
                "PAUSE",
                "RETRY",
                "RESET",
             ],
             "unavailable_actions": [
                 "START",
                 "CHANGE",
                 "DELETE",
                 "QUERY_PRE_CHECK",
                 "SWITCH_OVER",
                 "MODIFY_SPECIFICATION_ID",
                 "START_INCR",
                 "MODIFY_TASK_NUMBER",
                 "CONTINUE_JOB",
                 "STOP_JOB",
                 "CONTINUE_CAPTURE",
                 "STOP_CAPTURE",
                 "CONTINUE_APPLY",
                 "API_CONFIGURATION_ACTION",
                 "STOP_APPLY",
                 "PAY_ORDER",
                 "UNSUBSCRIBE",
                 "TO_PERIOD",
                 "TO_RENEW",
                 "ORDER_INFO",
                 "CHANGE_FLAVOR",
                 "CLONE"
             ]
        }    
      }, {
        "id" : "140b5236-88ad-43c8-811c-1268453jb101",
        "name" : "DRS-0042-linxiaolu",
        "status" : "CONFIGURATION",
        "description" : "",
        "create_time" : "2020-12-19 16:23:24",
        "engine_type" : "mysql",
        "net_type" : "eip",
        "billing_tag" : false,
        "job_direction" : "up",
        "db_use_type" : "migration",
        "task_type" : "FULL_INCR_TRANS",
        "node_newFramework" : false
        "job_action": {
            "available_actions": [
                "CREATE",
                "START",
                "CHANGE",
                "CHOOSE_OBJECT",
                "PRE_CHECK",
                "CHANGE_MODE",
                "FREE_RESOURCE",
                "MODIFY_DB_CONFIG",
                "API_CONFIGURATION_ACTION"
            ],
            "unavailable_actions": [
                "RETRY",
                "RESET",
                "DELETE",
                "QUERY_PRE_CHECK",
                "SWITCH_OVER",
                "MODIFY_SPECIFICATION_ID",
                "RESET_DB_PWD",
                "MODIFY_CONFIGURATION",
                "PAUSE",
                "JUMP_RETRY",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "CONTINUE_JOB",
                "STOP_JOB",
                "CONTINUE_CAPTURE",
                "STOP_CAPTURE",
                "CONTINUE_APPLY",
                "STOP_APPLY",
                "PAY_ORDER",
                "UNSUBSCRIBE",
                "TO_PERIOD",
                "TO_RENEW",
                "ORDER_INFO",
                "CHANGE_FLAVOR",
                 "CLONE"
             ]
         }
      }, {
        "id" : "7f8e6f74-72d2-4ddd-bb8f-6c41397jb101",
        "name" : "DRS-0796",
        "status" : "RELEASE_RESOURCE_COMPLETE",
        "description" : "",
        "create_time" : "2020-12-18 10:48:11",
        "engine_type" : "mysql",
        "net_type" : "eip",
        "billing_tag" : false,
        "job_direction" : "non-dbs",
        "db_use_type" : "migration",
        "task_type" : "FULL_INCR_TRANS",
        "node_newFramework" : false
        "job_action": {
            "available_actions": [
                "CREATE",
                "DELETE",
                "PRE_CHECK",
                "CHANGE_MODE",
                "MODIFY_DB_CONFIG",
                "CLONE"
            ],
            "unavailable_actions": [
                "FREE_RESOURCE",
                "START",
                "CHANGE",
                "CHOOSE_OBJECT",
                "RETRY",
                "RESET",
                "QUERY_PRE_CHECK",
                "SWITCH_OVER",
                "MODIFY_SPECIFICATION_ID",
                "RESET_DB_PWD",
                "MODIFY_CONFIGURATION",
                "PAUSE",
                "JUMP_RETRY",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "CONTINUE_JOB",
                "STOP_JOB",
                "CONTINUE_CAPTURE",
                "STOP_CAPTURE",
                "CONTINUE_APPLY",
                "STOP_APPLY",
                "PAY_ORDER",
                "UNSUBSCRIBE",
                "TO_PERIOD",
                "TO_RENEW",
                "ORDER_INFO",
                "CHANGE_FLAVOR"
             ]
         }
      }, {
        "id" : "14d88eeb-ee7e-4d30-a46e-a5ec8eajb101",
        "name" : "masj-mysql_migration_down-1",
        "status" : "INCRE_TRANSFER_STARTED",
        "description" : "[using] api test 2\n1. 本接口是用来配置源库/目标库信息的,选表前必须执行\n2. 配置中的任务修改描述信息成功,202 success\n3. 增量迁移中的任务修改描述信息失败,202 failed DRS.M01504\nAnother operation is being performed on the migration task or the migration task is abnormal. Try again later./",
        "create_time" : "2020-12-15 15:43:02",
        "engine_type" : "mysql",
        "net_type" : "eip",
        "billing_tag" : true,
        "job_direction" : "down",
        "db_use_type" : "migration",
        "task_type" : "FULL_INCR_TRANS",
        "node_newFramework" : false
        "job_action":{
            "available_actions": [
                 "CREATE",
                 "CHOOSE_OBJECT",
                 "PRE_CHECK",
                 "CHANGE_MODE",
                 "FREE_RESOURCE",
                 "MODIFY_DB_CONFIG",
                 "RESET_DB_PWD",
                 "MODIFY_CONFIGURATION",
                 "PAUSE",
             ],
            "unavailable_actions": [
                 "START",
                 "RETRY",
                 "RESET",
                 "CHANGE",
                 "DELETE",
                 "QUERY_PRE_CHECK",
                 "SWITCH_OVER",
                 "MODIFY_SPECIFICATION_ID",
                 "START_INCR",
                 "MODIFY_TASK_NUMBER",
                 "CONTINUE_JOB",
                 "STOP_JOB",
                 "CONTINUE_CAPTURE",
                 "STOP_CAPTURE",
                 "CONTINUE_APPLY",
                 "API_CONFIGURATION_ACTION",
                 "STOP_APPLY",
                 "PAY_ORDER",
                 "UNSUBSCRIBE",
                 "TO_PERIOD",
                 "TO_RENEW",
                 "ORDER_INFO",
                 "CHANGE_FLAVOR",
                 "CLONE"
             ]
        }    
      }, {
        "id" : "d54691d2-f105-434d-a75d-809b017jb101",
        "name" : "masj-2-mysql_migration_down",
        "status" : "CONFIGURATION",
        "description" : "[using] api test 2\n1. 本接口是用来配置源库/目标库信息的,选表前必须执行\n2. 配置中的任务修改描述信息成功,202 success\n3. 增量迁移中的任务修改描述信息失败,202 failed DRS.M01504\nAnother operation is being performed on the migration task or the migration task is abnormal. Try again later./",
        "create_time" : "2020-12-14 21:39:07",
        "engine_type" : "mysql",
        "net_type" : "eip",
        "billing_tag" : false,
        "job_direction" : "down",
        "db_use_type" : "migration",
        "task_type" : "FULL_INCR_TRANS",
        "node_newFramework" : false
        "job_action": {
            "available_actions": [
                "CREATE",
                "START",
                "CHANGE",
                "CHOOSE_OBJECT",
                "PRE_CHECK",
                "CHANGE_MODE",
                "FREE_RESOURCE",
                "MODIFY_DB_CONFIG",
                "API_CONFIGURATION_ACTION"
            ],
            "unavailable_actions": [
                "RETRY",
                "RESET",
                "DELETE",
                "QUERY_PRE_CHECK",
                "SWITCH_OVER",
                "MODIFY_SPECIFICATION_ID",
                "RESET_DB_PWD",
                "MODIFY_CONFIGURATION",
                "PAUSE",
                "JUMP_RETRY",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "CONTINUE_JOB",
                "STOP_JOB",
                "CONTINUE_CAPTURE",
                "STOP_CAPTURE",
                "CONTINUE_APPLY",
                "STOP_APPLY",
                "PAY_ORDER",
                "UNSUBSCRIBE",
                "TO_PERIOD",
                "TO_RENEW",
                "ORDER_INFO",
                "CHANGE_FLAVOR",
                 "CLONE"
             ]
         }
      } ],
      "total_record" : 7
    }
  • 查询实时同步任务列表示例 :
    {
      "jobs" : [ {
        "id" : "7994aac9-0a15-4fdb-bcc5-667f088jb20b",
        "name" : "DRS-8200",
        "status" : "CREATE_FAILED",
        "description" : "",
        "create_time" : "2020-12-21 18:02:36",
        "error_msg" : "system error!",
        "engine_type" : "oracle-to-mysql",
        "net_type" : "eip",
        "billing_tag" : false,
        "job_direction" : "up",
        "db_use_type" : "sync",
        "task_type" : "FULL_INCR_TRANS",
        "node_newFramework" : false
        "job_action": {
            "available_actions": [
                "CREATE",
                "DELETE",
                "START",
                "CHANGE",
                "CHOOSE_OBJECT",
                "PRE_CHECK",
                "CHANGE_MODE",
                "MODIFY_DB_CONFIG",
                "API_CONFIGURATION_ACTION"
            ],
            "unavailable_actions": [
                "FREE_RESOURCE",
                "RETRY",
                "RESET",
                "QUERY_PRE_CHECK",
                "SWITCH_OVER",
                "MODIFY_SPECIFICATION_ID",
                "RESET_DB_PWD",
                "MODIFY_CONFIGURATION",
                "PAUSE",
                "JUMP_RETRY",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "CONTINUE_JOB",
                "STOP_JOB",
                "CONTINUE_CAPTURE",
                "STOP_CAPTURE",
                "CONTINUE_APPLY",
                "STOP_APPLY",
                "PAY_ORDER",
                "UNSUBSCRIBE",
                "TO_PERIOD",
                "TO_RENEW",
                "ORDER_INFO",
                "CHANGE_FLAVOR",
                 "CLONE"
             ]
         }
      }, {
        "id" : "f463331d-e079-4689-bbef-4553202jb20b",
        "name" : "DRS-1285",
        "status" : "CONFIGURATION",
        "description" : "",
        "create_time" : "2020-12-21 17:19:38",
        "engine_type" : "oracle-to-mysql",
        "net_type" : "eip",
        "billing_tag" : false,
        "job_direction" : "up",
        "db_use_type" : "sync",
        "task_type" : "FULL_INCR_TRANS",
        "node_newFramework" : false
        "job_action": {
            "available_actions": [
                "CREATE",
                "START",
                "CHANGE",
                "CHOOSE_OBJECT",
                "PRE_CHECK",
                "CHANGE_MODE",
                "FREE_RESOURCE",
                "MODIFY_DB_CONFIG",
                "API_CONFIGURATION_ACTION"
            ],
            "unavailable_actions": [
                "RETRY",
                "RESET",
                "DELETE",
                "QUERY_PRE_CHECK",
                "SWITCH_OVER",
                "MODIFY_SPECIFICATION_ID",
                "RESET_DB_PWD",
                "MODIFY_CONFIGURATION",
                "PAUSE",
                "JUMP_RETRY",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "CONTINUE_JOB",
                "STOP_JOB",
                "CONTINUE_CAPTURE",
                "STOP_CAPTURE",
                "CONTINUE_APPLY",
                "STOP_APPLY",
                "PAY_ORDER",
                "UNSUBSCRIBE",
                "TO_PERIOD",
                "TO_RENEW",
                "ORDER_INFO",
                "CHANGE_FLAVOR",
                 "CLONE"
             ]
         }
      }, {
        "id" : "7f13c511-c35b-4f82-92ae-83bcbf0jb201",
        "name" : "DRS-9383",
        "status" : "CONFIGURATION",
        "description" : "",
        "create_time" : "2020-12-21 17:18:44",
        "engine_type" : "mysql",
        "net_type" : "eip",
        "billing_tag" : false,
        "job_direction" : "up",
        "db_use_type" : "sync",
        "task_type" : "FULL_INCR_TRANS",
        "node_newFramework" : false
        "job_action": {
            "available_actions": [
                "CREATE",
                "START",
                "CHANGE",
                "CHOOSE_OBJECT",
                "PRE_CHECK",
                "CHANGE_MODE",
                "FREE_RESOURCE",
                "MODIFY_DB_CONFIG",
                "API_CONFIGURATION_ACTION"
            ],
            "unavailable_actions": [
                "RETRY",
                "RESET",
                "DELETE",
                "QUERY_PRE_CHECK",
                "SWITCH_OVER",
                "MODIFY_SPECIFICATION_ID",
                "RESET_DB_PWD",
                "MODIFY_CONFIGURATION",
                "PAUSE",
                "JUMP_RETRY",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "CONTINUE_JOB",
                "STOP_JOB",
                "CONTINUE_CAPTURE",
                "STOP_CAPTURE",
                "CONTINUE_APPLY",
                "STOP_APPLY",
                "PAY_ORDER",
                "UNSUBSCRIBE",
                "TO_PERIOD",
                "TO_RENEW",
                "ORDER_INFO",
                "CHANGE_FLAVOR",
                 "CLONE"
             ]
         }
      }, {
        "id" : "7686e879-46a4-4d6b-bda9-5540424jb201",
        "name" : "DRS-9272",
        "status" : "CONFIGURATION",
        "description" : "",
        "create_time" : "2020-12-21 16:53:36",
        "engine_type" : "mysql",
        "net_type" : "eip",
        "billing_tag" : false,
        "job_direction" : "up",
        "db_use_type" : "sync",
        "task_type" : "FULL_INCR_TRANS",
        "node_newFramework" : false
        "job_action": {
            "available_actions": [
                "CREATE",
                "START",
                "CHANGE",
                "CHOOSE_OBJECT",
                "PRE_CHECK",
                "CHANGE_MODE",
                "FREE_RESOURCE",
                "MODIFY_DB_CONFIG",
                "API_CONFIGURATION_ACTION"
            ],
            "unavailable_actions": [
                "RETRY",
                "RESET",
                "DELETE",
                "QUERY_PRE_CHECK",
                "SWITCH_OVER",
                "MODIFY_SPECIFICATION_ID",
                "RESET_DB_PWD",
                "MODIFY_CONFIGURATION",
                "PAUSE",
                "JUMP_RETRY",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "CONTINUE_JOB",
                "STOP_JOB",
                "CONTINUE_CAPTURE",
                "STOP_CAPTURE",
                "CONTINUE_APPLY",
                "STOP_APPLY",
                "PAY_ORDER",
                "UNSUBSCRIBE",
                "TO_PERIOD",
                "TO_RENEW",
                "ORDER_INFO",
                "CHANGE_FLAVOR",
                 "CLONE"
             ]
         }
      }, {
        "id" : "5b2c2ec8-430e-4de0-937b-9d9547ajb201",
        "name" : "DRS-2899",
        "status" : "RELEASE_RESOURCE_COMPLETE",
        "description" : "",
        "create_time" : "2020-12-21 16:24:24",
        "engine_type" : "mysql",
        "net_type" : "eip",
        "billing_tag" : false,
        "job_direction" : "up",
        "db_use_type" : "sync",
        "task_type" : "FULL_INCR_TRANS",
        "node_newFramework" : false
        "job_action": {
            "available_actions": [
                "CREATE",
                "DELETE",
                "PRE_CHECK",
                "CHANGE_MODE",
                "MODIFY_DB_CONFIG",
                "CLONE"
            ],
            "unavailable_actions": [
                "FREE_RESOURCE",
                "START",
                "CHANGE",
                "CHOOSE_OBJECT",
                "RETRY",
                "RESET",
                "QUERY_PRE_CHECK",
                "SWITCH_OVER",
                "MODIFY_SPECIFICATION_ID",
                "RESET_DB_PWD",
                "MODIFY_CONFIGURATION",
                "PAUSE",
                "JUMP_RETRY",
                "START_INCR",
                "MODIFY_TASK_NUMBER",
                "CONTINUE_JOB",
                "STOP_JOB",
                "CONTINUE_CAPTURE",
                "STOP_CAPTURE",
                "CONTINUE_APPLY",
                "STOP_APPLY",
                "PAY_ORDER",
                "UNSUBSCRIBE",
                "TO_PERIOD",
                "TO_RENEW",
                "ORDER_INFO",
                "CHANGE_FLAVOR"
             ]
         }
      } ],
      "total_record" : 18
    }

状态码

状态码

描述

200

OK

400

Bad Request

错误码

请参见错误码