DescribeActiveOperationTasks

Updated at:

Queries the details of scheduled O&M tasks for MongoDB instances.

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

dds:DescribeActiveOperationTasks

list

*Instance

acs:dds:{#regionId}:{#accountId}:dbinstance/{#dbinstanceId}

None None

Request parameters

Parameter

Type

Required

Description

Example

Region

string

No

The ID of the region to which the pending event belongs. You can call the DescribeRegions operation to query the region ID.

Note

A value of all specifies all region IDs.

cn-beijing

TaskType

string

No

The task type. Valid values:

  • rds_apsaradb_ha: primary/secondary node switch

  • rds_apsaradb_transfer: instance migration

  • rds_apsaradb_upgrade: minor version upgrade

  • rds_apsaradb_maxscale: proxy minor version upgrade

  • all: all task types

all

PageSize

integer

No

The number of entries per page. Valid values: 30, 50, and 100. Default value: 30.

30

PageNumber

integer

No

The page number. The value must be greater than 0. Default value: 1.

1

ProductId

string

No

The product name. For MongoDB instances, set the value to MongoDB.

MongoDB

DbType

string

No

The database type. Default value: all.

mongoDb

Status

integer

No

The task status, which is used to filter the returned tasks. Valid values:

  • -1: all tasks

  • 3: pending tasks

  • 4: in-progress tasks

  • 5: successfully completed tasks

  • 6: failed tasks

  • 7: canceled tasks

-1

InsName

string

No

The name of the instance. This parameter is optional. If you specify this parameter, you can specify only one instance name.

dds-bp16aaccfe10****

AllowChange

integer

No

Specifies whether the execution time can be modified. Valid values:

  • -1 (default): returns all tasks.

  • 0: returns only tasks whose execution time cannot be modified.

  • 1: returns only tasks whose execution time can be modified.

-1

AllowCancel

integer

No

Specifies whether the task can be canceled. Valid values:

  • -1 (default): returns all tasks.

  • 0: returns only tasks that cannot be canceled.

  • 1: returns only tasks that can be canceled.

-1

ChangeLevel

string

No

The change level. Valid values:

  • all (default): returns all tasks.

  • S0: returns tasks at the exception remediation level.

  • S1: returns tasks at the system O&M level.

all

ResourceGroupId

string

No

The ID of the resource group.

rg-acfmyiu4ekp****

Response elements

Element

Type

Description

Example

object

PageNumber

integer

The page number.

1

RequestId

string

The request ID.

111E7B16-0A87-4CBA-B271-F34AD61E****

PageSize

integer

The number of entries per page.

30

TotalRecordCount

integer

The total number of returned task records.

1

Items

array<object>

The O&M tasks.

object

Status

integer

The task status. Valid values:

  • 3: pending tasks

  • 4: in-progress tasks

  • 5: successfully completed tasks

  • 6: failed tasks

  • 7: canceled tasks

3

ChangeLevelEn

string

The event level in English.

System maintenance

TaskType

string

The task type. Valid values:

  • rds_apsaradb_ha: primary/secondary node switch

  • rds_apsaradb_transfer: instance migration

  • rds_apsaradb_upgrade: minor version upgrade

  • rds_apsaradb_maxscale: proxy minor version upgrade

  • all: all task types

rds_apsaradb_upgrade

InsName

string

The name of the instance.

dds-bp16aaccfe10****

Region

string

The ID of the region to which the pending event belongs.

cn-beijing

ImpactZh

string

The event impact in Chinese.

Transient instance disconnection

CreatedTime

string

The creation time. The time follows the yyyy-mm-ddThh:mm:ssZ format. The time is displayed in UTC.

2023-05-30T14:30:00Z

SwitchTime

string

The time when the backend initiates the switchover. The time follows the yyyy-mm-ddThh:mm:ssZ format. The time is displayed in UTC.

2023-05-30T14:30:00Z

ChangeLevelZh

string

The event level in Chinese.

System O&M

Deadline

string

The deadline for adjusting the task execution time. The time follows the yyyy-mm-ddThh:mm:ssZ format. The time is displayed in UTC.

2023-05-30T23:59:59Z

PrepareInterval

string

The preparation time required between the start time of the O&M task and the switchover time. The time follows the HH:mm:ss format.

04:00:00

TaskTypeZh

string

The task reason in Chinese.

Minor version upgrade

CurrentAVZ

string

The current zone.

cn-beijing-h

AllowChange

string

Specifies whether the execution time can be modified. Valid values:

  • 1: The execution time can be modified.

  • 0: The execution time cannot be modified.

1

DbVersion

string

The database DPI engine version number.

5.6

ImpactEn

string

The event impact in English.

Transient instance disconnection

InsComment

string

The alias or description of the instance.

test

StartTime

string

The time when the backend executes the task. The time follows the yyyy-mm-ddThh:mm:ssZ format. The time is displayed in UTC.

2023-05-30T00:00:00Z

ModifiedTime

string

The modification time. The time follows the yyyy-mm-ddThh:mm:ssZ format. The time is displayed in UTC.

2023-05-30T14:30:00Z

AllowCancel

string

Specifies whether the task can be canceled. Valid values:

  • 1: The task can be canceled.

  • 0: The task cannot be canceled.

1

DbType

string

The type of the database engine.

mongoDb

ChangeLevel

string

The event level code. Valid values:

  • S1: system O&M

  • S0: risk remediation

S1

TaskTypeEn

string

The task reason in English.

Minor version update

ResultInfo

string

The execution result information.

userCancel

Id

integer

The task ID.

11111

SubInsNames

array

The child instances.

string

The name of the child task.

sub1369716295573-tes2cy6****.2013052818****

TaskParams

string

The task parameters.

""

Examples

Success response

JSON format

{
  "PageNumber": 1,
  "RequestId": "111E7B16-0A87-4CBA-B271-F34AD61E****",
  "PageSize": 30,
  "TotalRecordCount": 1,
  "Items": [
    {
      "Status": 3,
      "ChangeLevelEn": "System maintenance",
      "TaskType": "rds_apsaradb_upgrade",
      "InsName": "dds-bp16aaccfe10****",
      "Region": "cn-beijing\n",
      "ImpactZh": "实例闪断",
      "CreatedTime": "2023-05-30T14:30:00Z",
      "SwitchTime": "2023-05-30T14:30:00Z",
      "ChangeLevelZh": "系统运维",
      "Deadline": "2023-05-30T23:59:59Z",
      "PrepareInterval": "04:00:00",
      "TaskTypeZh": "小版本升级",
      "CurrentAVZ": "cn-beijing-h",
      "AllowChange": "1",
      "DbVersion": "5.6",
      "ImpactEn": "Transient instance disconnection\n",
      "InsComment": "test",
      "StartTime": "2023-05-30T00:00:00Z",
      "ModifiedTime": "2023-05-30T14:30:00Z\n",
      "AllowCancel": "1",
      "DbType": "mongoDb",
      "ChangeLevel": "S1",
      "TaskTypeEn": "Minor version update\n",
      "ResultInfo": "userCancel",
      "Id": 11111,
      "SubInsNames": [
        "sub1369716295573-tes2cy6****.2013052818****"
      ],
      "TaskParams": "\"\""
    }
  ]
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.