Queries the analysis period and generation status of the index analysis report on an ApsaraDB for MongoDB instance.

Before you call this operation, make sure that the ApsaraDB for Redis instance meets the following requirements:

  • The region of the instance is China (Hangzhou), China (Shanghai), China (Shenzhen), China (Qingdao), or China (Beijing).
  • The instance is a replica set instance or a sharded cluster instance.
  • The log audit function must be enabled for the instance.
Note You can call the CreateRecommendationTask operation to create an online task to analyze the indexes that were generated at any time within seven days (accurate to the hour). After the analysis is completed, the results are automatically converted to searchable data.

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 DescribeAvailableTimeRange

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

InstanceId String Yes dds-bpxxxxxxxx

The ID of the instance.

Note If you set this parameter to the ID of a sharded cluster instance, you must also specify the NodeId parameter.
NodeId String No d-bpxxxxxxxx

The ID of the shard node in the sharded cluster instance.

Note This parameter takes effect only when you set the DBInstanceId parameter to the ID of a sharded cluster instance.
RegionId String No cn-hangzhou

The region ID of the instance. You can call the DescribeDBInstanceAttribute operation to query the region ID of an instance.

AccessKeyId String No LTAIgbTGpxxxxxx

The AccessKey ID provided to you by Alibaba Cloud.

Response parameters

Parameter Type Example Description
TimeRange

The time range in which the generation status of the index report is queried.

EndTime String 2019-03-12T16Z

The end of the time range to query. The time is in the yyyy-MM-ddTHHZ format. The time is displayed in UTC.

NodeId String d-bpxxxxxxxx

The ID of the shard node in the sharded cluster instance.

Note This parameter is returned when the instance type is sharded cluster.
StartTime String 2019-03-11T16Z

The beginning of the time range to query. Specify the time in the yyyy-MM-ddTHHZ format. The time must be in UTC.

Status String Success

The generation status of the index recommendation report.

  • Success
  • Creating
  • Failure
TaskId String 3223xxxx

The ID of the job.

RequestId String 5C344679-EDD7-4BC1-964B-DDE01C507BE5

The ID of the request.

Examples

Sample requests


http(s)://mongodb.aliyuncs.com/? Action=DescribeAvailableTimeRange
&InstanceId=dds-bpxxxxxxxx
&<Common request parameters>

Sample success responses

XML format

<DescribeAvailableTimeRangeResponse>
	  <TimeRange>
		    <TimeRange>
			      <Status>Success</Status>
			      <EndTime>2019-03-12T16Z</EndTime>
			      <TaskId>3223xxxx</TaskId>
			      <StartTime>2019-03-11T16Z</StartTime>
		    </TimeRange>
	  </TimeRange>
	  <RequestId>5C344679-EDD7-4BC1-964B-DDE01C507BE5</RequestId>
</DescribeAvailableTimeRangeResponse>

JSON format

{ &quot;TimeRange&quot;:{ &quot;TimeRange&quot;:[ { &quot;Status&quot;:&quot;Success&quot;, &quot;EndTime&quot;:&quot;2019-03-12T16Z&quot;, &quot;StartTime&quot;:&quot;2019-03-11T16Z&quot;, &quot;TaskId&quot;:&quot;3223xxxx&quot; } ] }, &quot;RequestId&quot;:&quot;5C344679-EDD7-4BC1-964B-DDE01C507BE5&quot; }

Error codes

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