All Products
Search
Document Center

MaxCompute:ListMmsTasks

Last Updated:Oct 11, 2025

Retrieves a list of migration tasks.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

odps:ListMmsTasks

list

*project

acs:odps:{#regionId}:{#accountId}:mmsdatasource/{#sourceId}

None None

Request syntax

GET /api/v1/mms/datasources/{sourceId}/tasks HTTP/1.1

Request parameters

Parameter

Type

Required

Description

Example

sourceId

integer

Yes

The ID of the data source.

2000028

jobId

integer

No

The ID of the migration job.

10

jobName

string

No

The name of the job.

test1

srcDbName

string

No

The name of the source database.

test_db_1

srcTableName

string

No

The name of the source table.

test_table_1

dstDbName

string

No

The destination MaxCompute project.

mms_test

dstTableName

string

No

The destination MaxCompute table.

test_table_1

status

string

No

The status of the migration task.

Valid values:

  • INIT :

    未执行

  • DONE :

    成功

  • VERIFICATION_FAILED :

    数据校验失败

  • SCHEMA_DONE :

    迁移 schema 成功

  • SCHEMA_DOING :

    迁移 schema 中

  • VERIFICATION_DOING :

    数据校验中

  • SCHEMA_FAILED :

    迁移 schema 失败

  • VERIFICATION_DONE :

    数据校验成功

  • DATA_DOING :

    迁移数据中

  • DATA_DONE :

    迁移数据成功

  • DATA_FAILED :

    迁移数据失败

DATA_DOING

partition

string

No

The partition value. This parameter is used to filter migration tasks by a specific partition value.

p1=1/p2=abc

pageNum

integer

No

The page number.

1

pageSize

integer

No

The number of entries per page.

10

sorter.startTime

string

No

Sorts tasks by start time.

Valid values:

  • asc :

    升序

  • desc :

    降序

desc

sorter.status

string

No

Sorts tasks by status.

Valid values:

  • asc :

    升序

  • desc :

    降序

asc

Response elements

Element

Type

Description

Example

object

The returned data.

requestId

string

The request ID.

373A5CB2-8570-53BE-A98F-729B11D7A8B0

data

object

The returned data.

total

integer

The total number of records.

100

objectList

array<object>

The list of migration tasks.

object

The migration task object.

id

integer

The ID of the migration task.

2323

jobId

integer

The ID of the migration job.

87

sourceId

integer

The ID of the data source.

2000028

dbId

integer

The ID of the source database.

196

tableId

integer

The ID of the source table.

23

jobName

string

The name of the migration job.

test_odps_spark

sourceName

string

The name of the data source.

demo

srcDbName

string

The name of the source database.

db_1

srcSchemaName

string

The name of the source schema. This parameter specifies the schema in a Layer 3 namespace.

default

srcTableName

string

The name of the source table.

table_1

dstDbName

string

The destination MaxCompute project.

mms_test

dstSchemaName

string

The destination MaxCompute schema.

default

dstTableName

string

The destination MaxCompute table.

table_1

type

string

The task type.

Valid values:

  • HIVE :

    通过 HIve UDTF 迁移

  • BIGQUERY :

    通过 Read Api 迁移

BIGQUERY

status

string

The status of the migration task.

Valid values:

  • INIT :

    未运行

  • DONE :

    成功

  • SCHEMA_DONE :

    迁移 schema 成功

  • SCHEMA_DOING :

    迁移 schema 中

  • SCHEMA_FAILED :

    迁移 schema 失败

  • DATA_DOING :

    数据迁移中

  • DATA_DONE :

    数据迁移成功

  • DATA_FAILED :

    数据迁移失败

DATA_DOING

running

boolean

Indicates whether the task is running.

true

stopped

boolean

Indicates whether the task is stopped.

false

retriedTimes

integer

The number of retries.

1

startTime

string

The start time of the task.

2024-10-25 06:21:01

endTime

string

The end time of the task.

2024-10-25 07:21:01

createTime

string

The time when the task was created.

2024-10-25 04:21:01

pageNum

integer

The page number.

1

pageSize

integer

The number of entries per page.

10

Examples

Success response

JSON format

{
  "requestId": "373A5CB2-8570-53BE-A98F-729B11D7A8B0",
  "data": {
    "total": 100,
    "objectList": [
      {
        "id": 2323,
        "jobId": 87,
        "sourceId": 2000028,
        "dbId": 196,
        "tableId": 23,
        "jobName": "test_odps_spark",
        "sourceName": "demo ",
        "srcDbName": "db_1",
        "srcSchemaName": "default",
        "srcTableName": "table_1",
        "dstDbName": "mms_test",
        "dstSchemaName": "default",
        "dstTableName": "table_1",
        "type": "BIGQUERY",
        "status": "DATA_DOING",
        "running": true,
        "stopped": false,
        "retriedTimes": 1,
        "startTime": "2024-10-25 06:21:01",
        "endTime": "2024-10-25 07:21:01\n",
        "createTime": "2024-10-25 04:21:01\n"
      }
    ],
    "pageNum": 1,
    "pageSize": 10
  }
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.