Queries the performance data of an ApsaraDB for MongoDB instance.

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 DescribeDBInstancePerformance

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

Key String Yes MongoDB_DetailedSpaceUsage

The performance indicator. For more information about valid values, see Performance parameters.

Note Separate multiple metrics with commas (,).
StartTime String Yes 2019-03-11T12:30Z

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

EndTime String Yes 2019-03-11T12:30Z

The end of the time range to query. Specify the time in the yyyy-MM-ddTHH:mmZ format. The time must be in UTC.

DBInstanceId 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 mongos or shard node in a sharded cluster instance. You can specify this parameter to view the performance of a single node.

Note This parameter takes effect only when you set the DBInstanceId parameter to the ID of a sharded cluster instance.
RoleId String No 60xxxxx

The role ID of a node in a instance. You can call the DescribeReplicaSetRole operation to view role IDs.

Note This parameter is only valid when you specify the DBInstanceId parameter to the ID of a standalone instance or a replica set instance.
ReplicaSetRole String No Primary

The role of the node. Valid values:

  • Primary
  • Secondary
Note If you set the DBInstanceId parameter to the ID of a standalone instance, the value of this parameter can only be Primary.
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
RequestId String 267F98DC-367D-4F20-B137-8B5B664D1C5D

The ID of the request.

StartTime String 2019-03-11T12:20Z

The beginning of the time range to query. The time is in the yyyy-MM-ddTHH:mmZ format. The time is displayed in UTC.

EndTime String 2019-03-11T12:30Z

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

PerformanceKeys

Details about performance metrics.

Key String MongoDB_DetailedSpaceUsage

Performance metric.

PerformanceValues

Details about the values of performance metrics.

Date String 2019-03-11T12:21:51Z

The date and time when the value is generated.

Value String 0.6

The value of a performance metric.

Unit String MB

The unit of the performance metric.

ValueFormat String cpu_usage

The format of the performance metric value. If the performance indicator contains multiple fields, the fields are separated with ampersands (&).

For example, if you query disk space usage, the returned ValueFormat is ins_size&data_size&log_size.

Examples

Sample requests


http(s)://mongodb.aliyuncs.com/? Action=DescribeDBInstancePerformance
&Key=MongoDB_DetailedSpaceUsage
&StartTime=2019-03-11T12:30Z
&EndTime=2019-03-11T12:30Z
&DBInstanceId=dds-bpxxxxxxxx
&<Common request parameters>

Sample success responses

XML format

<DescribeDBInstancePerformanceResponse>
	  <RequestId>267F98DC-367D-4F20-B137-8B5B664D1C5D</RequestId>
	  <PerformanceKeys>
		    <PerformanceKey>
			      <Key>MongoDB_DetailedSpaceUsage</Key>
			      <PerformanceValues>
				        <PerformanceValue>
					          <Value>1768&amp;1282&amp;486</Value>
					          <Date>2019-03-11T12:21:51Z</Date>
				        </PerformanceValue>
				        <PerformanceValue>
					          <Value>1768&amp;1282&amp;486</Value>
					          <Date>2019-03-11T12:26:52Z</Date>
				        </PerformanceValue>
			      </PerformanceValues>
			      <Unit>MB</Unit>
			      <ValueFormat>ins_size&amp;data_size&amp;log_size</ValueFormat>
		    </PerformanceKey>
	  </PerformanceKeys>
	  <EndTime>2019-03-11T12:30Z</EndTime>
	  <StartTime>2019-03-11T12:20Z</StartTime>
</DescribeDBInstancePerformanceResponse>

JSON format

{ &quot;RequestId&quot;:&quot;267F98DC-367D-4F20-B137-8B5B664D1C5D&quot;, &quot;PerformanceKeys&quot;:{ &quot;PerformanceKey&quot;:[ { &quot;Key&quot;:&quot;MongoDB_DetailedSpaceUsage&quot;, &quot;PerformanceValues&quot;:{ &quot;PerformanceValue&quot;:[ { &quot;Value&quot;:&quot;1768&amp;1282&amp;486&quot;, &quot;Date&quot;:&quot;2019-03-11T12:21:51Z&quot; }, { &quot;Value&quot;:&quot;1768&amp;1282&amp;486&quot;, &quot;Date&quot;:&quot;2019-03-11T12:26:52Z&quot; } ] }, &quot;Unit&quot;:&quot;MB&quot;, &quot;ValueFormat&quot;:&quot;ins_size&amp;data_size&amp;log_size&quot; } ] }, &quot;EndTime&quot;:&quot;2019-03-11T12:30Z&quot;, &quot;StartTime&quot;:&quot;2019-03-11T12:20Z&quot; }

Error codes

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