listPerformanceAnalysisReports method
Lists all the analysis reports created for the DB instance. The reports are sorted based on the start time of each report.
May throw InternalServiceError.
May throw InvalidArgumentException.
May throw NotAuthorizedException.
Parameter identifier :
An immutable identifier for a data source that is unique for an Amazon Web
Services Region. Performance Insights gathers metrics from this data
source. In the console, the identifier is shown as ResourceID. When
you call DescribeDBInstances, the identifier is returned as
DbiResourceId.
To use a DB instance as a data source, specify its
DbiResourceId value. For example, specify
db-ABCDEFGHIJKLMNOPQRSTU1VW2X.
Parameter serviceType :
The Amazon Web Services service for which Performance Insights returns
metrics. Valid value is RDS.
Parameter listTags :
Specifies whether or not to include the list of tags in the response.
Parameter maxResults :
The maximum number of items to return in the response. If more items exist
than the specified MaxResults value, a pagination token is
included in the response so that the remaining results can be retrieved.
Parameter nextToken :
An optional pagination token provided by a previous request. If this
parameter is specified, the response includes only records beyond the
token, up to the value specified by MaxResults.
Implementation
Future<ListPerformanceAnalysisReportsResponse>
listPerformanceAnalysisReports({
required String identifier,
required ServiceType serviceType,
bool? listTags,
int? maxResults,
String? nextToken,
}) async {
_s.validateNumRange(
'maxResults',
maxResults,
0,
25,
);
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target':
'PerformanceInsightsv20180227.ListPerformanceAnalysisReports'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'Identifier': identifier,
'ServiceType': serviceType.value,
if (listTags != null) 'ListTags': listTags,
if (maxResults != null) 'MaxResults': maxResults,
if (nextToken != null) 'NextToken': nextToken,
},
);
return ListPerformanceAnalysisReportsResponse.fromJson(jsonResponse.body);
}