GetPerformanceAnalysisReport - Amazon RDS Performance Insights
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

GetPerformanceAnalysisReport

Retrieves the report including the report ID, status, time details, and the insights with recommendations. The report status can be RUNNING, SUCCEEDED, or FAILED. The insights include the description and recommendation fields.

Request Syntax

{ "AcceptLanguage": "string", "AnalysisReportId": "string", "Identifier": "string", "ServiceType": "string", "TextFormat": "string" }

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters.

The request accepts the following data in JSON format.

Note

In the following list, the required parameters are described first.

AnalysisReportId

A unique identifier of the created analysis report. For example, report-12345678901234567

Type: String

Length Constraints: Minimum length of 1. Maximum length of 100.

Pattern: report-[0-9a-f]{17}

Required: Yes

Identifier

An immutable identifier for a data source that is unique for an Amazon 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.

Type: String

Length Constraints: Minimum length of 0. Maximum length of 256.

Pattern: ^[a-zA-Z0-9-]+$

Required: Yes

ServiceType

The Amazon service for which Performance Insights will return metrics. Valid value is RDS.

Type: String

Valid Values: RDS | DOCDB

Required: Yes

AcceptLanguage

The text language in the report. The default language is EN_US (English).

Type: String

Valid Values: EN_US

Required: No

TextFormat

Indicates the text format in the report. The options are PLAIN_TEXT or MARKDOWN. The default value is plain text.

Type: String

Valid Values: PLAIN_TEXT | MARKDOWN

Required: No

Response Syntax

{ "AnalysisReport": { "AnalysisReportId": "string", "CreateTime": number, "EndTime": number, "Identifier": "string", "Insights": [ { "BaselineData": [ { "PerformanceInsightsMetric": { "Dimensions": { "string" : "string" }, "DisplayName": "string", "Metric": "string", "Value": number } } ], "Context": "string", "Description": "string", "EndTime": number, "InsightData": [ { "PerformanceInsightsMetric": { "Dimensions": { "string" : "string" }, "DisplayName": "string", "Metric": "string", "Value": number } } ], "InsightId": "string", "InsightType": "string", "Recommendations": [ { "RecommendationDescription": "string", "RecommendationId": "string" } ], "Severity": "string", "StartTime": number, "SupportingInsights": [ "Insight" ] } ], "ServiceType": "string", "StartTime": number, "Status": "string" } }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

AnalysisReport

The summary of the performance analysis report created for a time period.

Type: AnalysisReport object

Errors

For information about the errors that are common to all actions, see Common Errors.

InternalServiceError

The request failed due to an unknown error.

HTTP Status Code: 500

InvalidArgumentException

One of the arguments provided is invalid for this request.

HTTP Status Code: 400

NotAuthorizedException

The user is not authorized to perform this request.

HTTP Status Code: 400

Examples

Retrieve a performance analysis report

The following example gets the report insights and other details for the report report-01234567890abcdef.

Sample Request

POST / HTTP/1.1 Host: <Hostname> Accept-Encoding: identity X-Amz-Target: PerformanceInsightsv20180227.GetPerformanceAnalysisReport Content-Type: application/x-amz-json-1.1 User-Agent: <UserAgentString> X-Amz-Date: <Date> Authorization: AWS4-HMAC-SHA256 Credential=<Credential>, SignedHeaders=<Headers>, Signature=<Signature> Content-Length: <PayloadSizeBytes> { "AnalysisReportId": "report-01234567890abcdef", "Identifier": "db-ABC1DEFGHIJKL2MNOPQRSTUV3W", "ServiceType": "RDS" }

Sample Response

HTTP/1.1 200 OK Content-Type: application/x-amz-json-1.1 Date: <Date> x-amzn-RequestId: <RequestId> Content-Length: <PayloadSizeBytes> Connection: keep-alive { "AnalysisReport": { "AnalysisReportId": "report-01234567890abcdef", "CreateTime": 1690906983.028, "EndTime": 1690453065, "Identifier": "db-ABC1DEFGHIJKL2MNOPQRSTUV3W", "Insights": [ { "BaselineData": [ { "PerformanceInsightsMetric": { "Dimensions": {}, "Metric": "db.load.avg", "Value": 0 } } ], "Context": "CAUSAL", "Description": "The database is idle, with no detectable load for the time range.", "EndTime": 1690453065, "InsightData": [ { "PerformanceInsightsMetric": { "Dimensions": {}, "Metric": "db.load.avg", "Value": 0 } } ], "InsightId": "MURCX0xPQURfWkVSTwY8NIdQhkWEeU19Zybf8H636v470O8ID2uUn6uLWFp5MDAwMDAwMDAw", "InsightType": "DB_LOAD_ZERO", "Recommendations": [ { "RecommendationDescription": "Try creating an analysis report for a different time range.", "RecommendationId": "MVJlY29tbWVuZGF0aW9uREJfTE9BRF9aRVJPvXe8CGe_f-ZX2tY-Em61aD6v2u9wcPi58j_zY28eKEwwMDAwMDAwMDA=" } ], "Severity": "LOW", "StartTime": 1690009222, "SupportingInsights": [] } ], "ServiceType": "RDS", "StartTime": 1690009222, "Status": "SUCCEEDED" } }

See Also

For more information about using this API in one of the language-specific Amazon SDKs, see the following: