Queries the details of an O&M event.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes DescribeMaintenanceAction

The operation that you want to perform. Set the value to DescribeMaintenanceAction.

Region String Yes cn-hangzhou

The ID of the region where the O&M event occurs. Valid values:

  • The ID of the region where the O&M event occurs. Example: cn-hangzhou. You can call the DescribeRegions operation to query the regions and zones supported by AnalyticDB for MySQL, including the region IDs.
  • You can also set Region to all to view all the O&M events in all regions. If Region is set to all, TaskType must be set to all.
TaskType String Yes rds_apsaradb_upgrade

The type of the O&M event. Valid values:

  • rds_apsaradb_upgrade: indicates database software upgrades.
  • all: indicates all the O&M events in all regions within the current account. If Region is set to all, TaskType must be set to all.
IsHistory Integer No 1

Specifies whether to return the details of pending or historical O&M events. Valid values:

  • 0: returns the details of pending O&M event.
  • 1: returns the details of historical O&M event.

If you do not specify this parameter, the details of pending O&M event are returned.

PageSize Integer No 30

The number of entries to return on each page. Valid values: 30, 50, and 100. Default value: 30.

PageNumber Integer No 1

The number of the page to return. The value must be an integer that is greater than 0. Default value: 1.

RegionId String Yes cn-hangzhou

The ID of the region where the O&M event occurs.

Note You can call the DescribeRegions operation to query the regions and zones supported by AnalyticDB for MySQL, including the region IDs.

Response parameters

Parameter Type Example Description
PageNumber Integer 1

The page number of the returned page.

RequestId String E774C8A9-8819-4A09-9E91-07C078******

The ID of the request.

PageSize Integer 30

The number of entries returned per page.

TotalRecordCount Integer 2

The total number of entries returned.

Items Array of Items

The list of events.

Status String SUCCESS

The state of the event.

  • If you set IsHistory to 0, the state of the pending O&M event is returned. Valid values:
    • WAITING_MODIFY: The start time of the O&M event is waiting to be set.
    • WAITING: The O&M event is waiting to be processed.
    • PROCESSING: The O&M event is being processed. The switching time of an event in this state cannot be changed.
  • If you set IsHistory to 1, the state of the historical O&M event is returned. Valid values:
    • SUCCESS: The event ended and the execution succeeded.
    • FAILED: The event ended but the execution failed.
    • CANCEL: The event was canceled.
Deadline String 2021-07-04T15:59:59Z

The deadline before which the event can be executed. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

PrepareInterval String 02:00:00

The preparation time that is required before the pending O&M event can be switched. The time is in the HH:mm:ss format.

DBType String analyticdb

The database engine.

StartTime String 2021-07-03T04:00:00Z

The time when the task was executed in the backend. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

TaskType String rds_apsaradb_upgrade

The type of the O&M event.

DBVersion String 3.0

The version of the database engine.

DBClusterId String am-****************

The ID of the cluster involved in the O&M event.

ModifiedTime String 2021-07-03T06:33:00Z

The point in time at which the O&M event was switched. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

Region String cn-hangzhou

The ID of the region where the O&M event occurs.

ResultInfo String autoCancel

The execution result of the O&M event.

Note This parameter is valid only when Status is set to FAILED or CANCEL.
CreatedTime String 2021-06-30T02:44:27Z

The time when the O&M event was created. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

Id Integer 11111

The ID of the event.

SwitchTime String 2021-07-03T06:00:00Z

The time when the pending event was switched. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

Examples

Sample requests

http(s)://adb.aliyuncs.com/?Action=DescribeMaintenanceAction
&Region=cn-hangzhou
&TaskType=rds_apsaradb_upgrade
&RegionId=cn-hangzhou
&<Common request parameters>

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<DescribeMaintenanceActionResponse>
    <TotalRecordCount>2</TotalRecordCount>
    <RequestId>E774C8A9-8819-4A09-9E91-07C078******</RequestId>
    <PageSize>30</PageSize>
    <PageNumber>1</PageNumber>
    <Items>
        <Status>SUCCESS</Status>
        <CreatedTime>2021-06-30T02:44:27Z</CreatedTime>
        <Deadline>2021-07-04T15:59:59Z</Deadline>
        <StartTime>2021-07-03T04:00:00Z</StartTime>
        <DBClusterId>am-****************</DBClusterId>
        <DBType>analyticdb</DBType>
        <DBVersion>3.0</DBVersion>
        <ModifiedTime>2021-07-03T06:33:00Z</ModifiedTime>
        <TaskType>rds_apsaradb_upgrade</TaskType>
        <PrepareInterval>02:00:00</PrepareInterval>
        <Region>cn-hangzhou</Region>
        <Id>11111</Id>
        <SwitchTime>2021-07-03T06:00:00Z</SwitchTime>
    </Items>
    <Items>
        <Status>CANCEL</Status>
        <CreatedTime>2021-06-25T06:32:45Z</CreatedTime>
        <Deadline>2021-06-29T15:59:59Z</Deadline>
        <StartTime>2021-06-26T16:10:00Z</StartTime>
        <DBClusterId>am-****************</DBClusterId>
        <DBType>analyticdb</DBType>
        <DBVersion>3.0</DBVersion>
        <ModifiedTime>2021-06-26T18:40:00Z</ModifiedTime>
        <TaskType>rds_apsaradb_upgrade</TaskType>
        <PrepareInterval>02:00:00</PrepareInterval>
        <Region>cn-hangzhou</Region>
        <Id>22222</Id>
        <ResultInfo>autoCancel</ResultInfo>
        <SwitchTime>2021-06-26T18:10:00Z</SwitchTime>
    </Items>
</DescribeMaintenanceActionResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "TotalRecordCount" : 2,
  "RequestId" : "E774C8A9-8819-4A09-9E91-07C078******",
  "PageSize" : 30,
  "PageNumber" : 1,
  "Items" : [ {
    "Status" : "SUCCESS",
    "CreatedTime" : "2021-06-30T02:44:27Z",
    "Deadline" : "2021-07-04T15:59:59Z",
    "StartTime" : "2021-07-03T04:00:00Z",
    "DBClusterId" : "am-****************",
    "DBType" : "analyticdb",
    "DBVersion" : 3,
    "ModifiedTime" : "2021-07-03T06:33:00Z",
    "TaskType" : "rds_apsaradb_upgrade",
    "PrepareInterval" : "02:00:00",
    "Region" : "cn-hangzhou",
    "Id" : 11111,
    "SwitchTime" : "2021-07-03T06:00:00Z"
  }, {
    "Status" : "CANCEL",
    "CreatedTime" : "2021-06-25T06:32:45Z",
    "Deadline" : "2021-06-29T15:59:59Z",
    "StartTime" : "2021-06-26T16:10:00Z",
    "DBClusterId" : "am-****************",
    "DBType" : "analyticdb",
    "DBVersion" : 3,
    "ModifiedTime" : "2021-06-26T18:40:00Z",
    "TaskType" : "rds_apsaradb_upgrade",
    "PrepareInterval" : "02:00:00",
    "Region" : "cn-hangzhou",
    "Id" : 22222,
    "ResultInfo" : "autoCancel",
    "SwitchTime" : "2021-06-26T18:10:00Z"
  } ]
}

Error codes

For a list of error codes, visit the API Error Center.