Skip to content

aws.compute_optimizer.get_rds_database_recommendations

Example SQL Queries

SELECT * FROM
aws.compute_optimizer.get_rds_database_recommendations;

Description

Returns Amazon RDS recommendations.

Compute Optimizer generates recommendations for Amazon RDS that meet a specific set of requirements. For more information, see the Supported resources and requirements in the Compute Optimizer User Guide.

Table Definition

Column NameColumn Data Type
account_ids Input Column

Return the Amazon RDS recommendations to the specified Amazon Web Services account IDs.

If your account is the management account or the delegated administrator of an organization, use this parameter to return the Amazon RDS recommendations to specific member accounts.

You can only specify one account ID per request.

VARCHAR[]
Show child fields
account_ids[]
filters Input Column

An array of objects to specify a filter that returns a more specific list of Amazon RDS recommendations.

STRUCT(
"name" VARCHAR,
"values" VARCHAR[]
)[]
Show child fields
filters[]
Show child fields
filters[].name

The name of the filter.

Specify Finding to return recommendations with a specific finding classification.

You can filter your Amazon RDS recommendations by tag:key and tag-key tags.

A tag:key is a key and value combination of a tag assigned to your Amazon RDS recommendations. Use the tag key in the filter name and the tag value as the filter value. For example, to find all Amazon RDS service recommendations that have a tag with the key of Owner and the value of TeamA, specify tag:Owner for the filter name and TeamA for the filter value.

A tag-key is the key of a tag assigned to your Amazon RDS recommendations. Use this filter to find all of your Amazon RDS recommendations that have a tag with a specific key. This doesn’t consider the tag value. For example, you can find your Amazon RDS service recommendations with a tag key value of Owner or without any tag keys assigned.

filters[].values[]
max_results Input Column

The maximum number of Amazon RDS recommendations to return with a single request.

To retrieve the remaining results, make another request with the returned nextToken value.

BIGINT
next_token Input Column

The token to advance to the next page of Amazon RDS recommendations.

VARCHAR
recommendation_preferences Input Column

Describes the recommendation preferences to return in the response of a GetAutoScalingGroupRecommendations, GetEC2InstanceRecommendations, GetEC2RecommendationProjectedMetrics, GetRDSDatabaseRecommendations, and GetRDSDatabaseRecommendationProjectedMetrics request.

STRUCT(
"cpu_vendor_architectures" VARCHAR[]
)
Show child fields
recommendation_preferences.cpu_vendor_architectures[]
resource_arns Input Column

The ARN that identifies the Amazon RDS.

The following is the format of the ARN:

arn:aws:rds:{region}:{accountId}:db:{resourceName}

The following is the format of a DB Cluster ARN:

arn:aws:rds:{region}:{accountId}:cluster:{resourceName}

VARCHAR[]
Show child fields
resource_arns[]
_aws_profile Input Column

The AWS profile defines the AWS identity used. It can be defined via credentials or by assuming a IAM role.

STRUCT(
"type" VARCHAR,
"name" VARCHAR,
"account_id" VARCHAR,
"via_profile_name" VARCHAR,
"assumed_role_arn" VARCHAR,
"organization" STRUCT(
"account_name" VARCHAR,
"id" VARCHAR,
"tags" STRUCT(
"key" VARCHAR,
"value" VARCHAR
)[],
"master_account" STRUCT(
"id" VARCHAR,
"email" VARCHAR
),
"parents" STRUCT(
"type" VARCHAR,
"id" VARCHAR,
"name" VARCHAR,
"tags" STRUCT(
"key" VARCHAR,
"value" VARCHAR
)[]
)[]
)
)
Show child fields
_aws_profile.account_id

The AWS account id

_aws_profile.assumed_role_arn

The ARN of the assumed role

_aws_profile.name

The unique name of the profile.

_aws_profile.organization

Information about this profile's membership in the AWS organization.

Show child fields
_aws_profile.organization.account_name

The name of account speciifed by the organization

_aws_profile.organization.id

The organization id

_aws_profile.organization.master_account
Show child fields
_aws_profile.organization.master_account.email

The organization master account email address

_aws_profile.organization.master_account.id

The organization master account id

_aws_profile.organization.parents[]
Show child fields
_aws_profile.organization.parents[].id

The id of the parent

_aws_profile.organization.parents[].name

The name of the parent

_aws_profile.organization.parents[].tags[]
Show child fields
_aws_profile.organization.parents[].tags[].key
_aws_profile.organization.parents[].tags[].value
_aws_profile.organization.parents[].type

The type of parent can be an organization unit or a root

_aws_profile.organization.tags[]
Show child fields
_aws_profile.organization.tags[].key
_aws_profile.organization.tags[].value
_aws_profile.type

The type of profile, either 'credentials' or 'assumed_role'

_aws_profile.via_profile_name

This IAM role for this profile is assumed by first utilizing another profile with this name to obtain credentials.

_aws_region Input Column

The AWS region to use.

VARCHAR
errors

An array of objects that describe errors of the request.

STRUCT(
"identifier" VARCHAR,
"code" VARCHAR,
"message" VARCHAR
)[]
Show child fields
errors[]
Show child fields
errors[].code

The error code.

errors[].identifier

The ID of the error.

errors[].message

The message, or reason, for the error.

rds_db_recommendations

An array of objects that describe the Amazon RDS recommendations.

STRUCT(
"resource_arn" VARCHAR,
"account_id" VARCHAR,
"engine" VARCHAR,
"engine_version" VARCHAR,
"current_db_instance_class" VARCHAR,
"current_storage_configuration" STRUCT(
"storage_type" VARCHAR,
"allocated_storage" BIGINT,
"iops" BIGINT,
"max_allocated_storage" BIGINT,
"storage_throughput" BIGINT
),
"idle" VARCHAR,
"instance_finding" VARCHAR,
"storage_finding" VARCHAR,
"instance_finding_reason_codes" VARCHAR[],
"storage_finding_reason_codes" VARCHAR[],
"instance_recommendation_options" STRUCT(
"db_instance_class" VARCHAR,
"projected_utilization_metrics" STRUCT(
"name" VARCHAR,
"statistic" VARCHAR,
"value" DOUBLE
)[],
"performance_risk" DOUBLE,
"rank" BIGINT,
"savings_opportunity" STRUCT(
"savings_opportunity_percentage" DOUBLE,
"estimated_monthly_savings" STRUCT(
"currency" VARCHAR,
"value" DOUBLE
)
),
"savings_opportunity_after_discounts" STRUCT(
"savings_opportunity_percentage" DOUBLE,
"estimated_monthly_savings" STRUCT(
"currency" VARCHAR,
"value" DOUBLE
)
)
)[],
"storage_recommendation_options" STRUCT(
"storage_configuration" STRUCT(
"storage_type" VARCHAR,
"allocated_storage" BIGINT,
"iops" BIGINT,
"max_allocated_storage" BIGINT,
"storage_throughput" BIGINT
),
"rank" BIGINT,
"savings_opportunity" STRUCT(
"savings_opportunity_percentage" DOUBLE,
"estimated_monthly_savings" STRUCT(
"currency" VARCHAR,
"value" DOUBLE
)
),
"savings_opportunity_after_discounts" STRUCT(
"savings_opportunity_percentage" DOUBLE,
"estimated_monthly_savings" STRUCT(
"currency" VARCHAR,
"value" DOUBLE
)
)
)[],
"utilization_metrics" STRUCT(
"name" VARCHAR,
"statistic" VARCHAR,
"value" DOUBLE
)[],
"effective_recommendation_preferences" STRUCT(
"cpu_vendor_architectures" VARCHAR[],
"enhanced_infrastructure_metrics" VARCHAR,
"look_back_period" VARCHAR,
"savings_estimation_mode" STRUCT(
"source" VARCHAR
)
),
"lookback_period_in_days" DOUBLE,
"last_refresh_timestamp" TIMESTAMP_S,
"tags" STRUCT(
"key" VARCHAR,
"value" VARCHAR
)[]
)[]
Show child fields
rds_db_recommendations[]
Show child fields
rds_db_recommendations[].account_id

The Amazon Web Services account ID of the Amazon RDS.

rds_db_recommendations[].current_db_instance_class

The DB instance class of the current RDS instance.

rds_db_recommendations[].current_storage_configuration

The configuration of the current RDS storage.

Show child fields
rds_db_recommendations[].current_storage_configuration.allocated_storage

The size of the RDS storage in gigabytes (GB).

rds_db_recommendations[].current_storage_configuration.iops

The provisioned IOPs of the RDS storage.

rds_db_recommendations[].current_storage_configuration.max_allocated_storage

The maximum limit in gibibytes (GiB) to which Amazon RDS can automatically scale the storage of the RDS instance.

rds_db_recommendations[].current_storage_configuration.storage_throughput

The storage throughput of the RDS storage.

rds_db_recommendations[].current_storage_configuration.storage_type

The type of RDS storage.

rds_db_recommendations[].effective_recommendation_preferences

Describes the effective recommendation preferences for Amazon RDS.

Show child fields
rds_db_recommendations[].effective_recommendation_preferences.cpu_vendor_architectures[]
rds_db_recommendations[].effective_recommendation_preferences.enhanced_infrastructure_metrics

Describes the activation status of the enhanced infrastructure metrics preference.

A status of Active confirms that the preference is applied in the latest recommendation refresh, and a status of Inactive confirms that it's not yet applied to recommendations.

For more information, see Enhanced infrastructure metrics in the Compute Optimizer User Guide.

rds_db_recommendations[].effective_recommendation_preferences.look_back_period

The number of days the utilization metrics of the Amazon RDS are analyzed.

rds_db_recommendations[].effective_recommendation_preferences.savings_estimation_mode

Describes the savings estimation mode preference applied for calculating savings opportunity for Amazon RDS.

Show child fields
rds_db_recommendations[].effective_recommendation_preferences.savings_estimation_mode.source

Describes the source for calculating the savings opportunity for Amazon RDS.

rds_db_recommendations[].engine

The engine of the RDS instance.

rds_db_recommendations[].engine_version

The database engine version.

rds_db_recommendations[].idle

This indicates if the RDS instance is idle or not.

rds_db_recommendations[].instance_finding

The finding classification of an Amazon RDS instance.

Findings for Amazon RDS instance include:

  • Underprovisioned — When Compute Optimizer detects that there’s not enough resource specifications, an Amazon RDS is considered under-provisioned.

  • Overprovisioned — When Compute Optimizer detects that there’s excessive resource specifications, an Amazon RDS is considered over-provisioned.

  • Optimized — When the specifications of your Amazon RDS instance meet the performance requirements of your workload, the service is considered optimized.

rds_db_recommendations[].instance_finding_reason_codes[]
rds_db_recommendations[].instance_recommendation_options[]
Show child fields
rds_db_recommendations[].instance_recommendation_options[].db_instance_class

Describes the DB instance class recommendation option for your Amazon RDS instance.

rds_db_recommendations[].instance_recommendation_options[].performance_risk

The performance risk of the RDS instance recommendation option.

rds_db_recommendations[].instance_recommendation_options[].projected_utilization_metrics[]
Show child fields
rds_db_recommendations[].instance_recommendation_options[].projected_utilization_metrics[].name

The name of the utilization metric.

rds_db_recommendations[].instance_recommendation_options[].projected_utilization_metrics[].statistic

The statistic of the utilization metric.

The Compute Optimizer API, Command Line Interface (CLI), and SDKs return utilization metrics using only the Maximum statistic, which is the highest value observed during the specified period.

The Compute Optimizer console displays graphs for some utilization metrics using the Average statistic, which is the value of Sum/SampleCount during the specified period. For more information, see Viewing resource recommendations in the Compute Optimizer User Guide. You can also get averaged utilization metric data for your resources using Amazon CloudWatch. For more information, see the Amazon CloudWatch User Guide.

rds_db_recommendations[].instance_recommendation_options[].projected_utilization_metrics[].value

The value of the utilization metric.

rds_db_recommendations[].instance_recommendation_options[].rank

The rank identifier of the RDS instance recommendation option.

rds_db_recommendations[].instance_recommendation_options[].savings_opportunity

Describes the savings opportunity for recommendations of a given resource type or for the recommendation option of an individual resource.

Savings opportunity represents the estimated monthly savings you can achieve by implementing a given Compute Optimizer recommendation.

Savings opportunity data requires that you opt in to Cost Explorer, as well as activate Receive Amazon EC2 resource recommendations in the Cost Explorer preferences page. That creates a connection between Cost Explorer and Compute Optimizer. With this connection, Cost Explorer generates savings estimates considering the price of existing resources, the price of recommended resources, and historical usage data. Estimated monthly savings reflects the projected dollar savings associated with each of the recommendations generated. For more information, see Enabling Cost Explorer and Optimizing your cost with Rightsizing Recommendations in the Cost Management User Guide.

Show child fields
rds_db_recommendations[].instance_recommendation_options[].savings_opportunity.estimated_monthly_savings

An object that describes the estimated monthly savings amount possible by adopting Compute Optimizer recommendations for a given resource. This is based on the On-Demand instance pricing..

Show child fields
rds_db_recommendations[].instance_recommendation_options[].savings_opportunity.estimated_monthly_savings.currency

The currency of the estimated monthly savings.

rds_db_recommendations[].instance_recommendation_options[].savings_opportunity.estimated_monthly_savings.value

The value of the estimated monthly savings.

rds_db_recommendations[].instance_recommendation_options[].savings_opportunity.savings_opportunity_percentage

The estimated monthly savings possible as a percentage of monthly cost by adopting Compute Optimizer recommendations for a given resource.

rds_db_recommendations[].instance_recommendation_options[].savings_opportunity_after_discounts

Describes the savings opportunity for Amazon RDS recommendations or for the recommendation option.

Savings opportunity represents the estimated monthly savings after applying Savings Plans discounts. You can achieve this by implementing a given Compute Optimizer recommendation.

Show child fields
rds_db_recommendations[].instance_recommendation_options[].savings_opportunity_after_discounts.estimated_monthly_savings

The estimated monthly savings possible by adopting Compute Optimizer’s Amazon RDS instance recommendations. This includes any applicable Savings Plans discounts.

Show child fields
rds_db_recommendations[].instance_recommendation_options[].savings_opportunity_after_discounts.estimated_monthly_savings.currency

The currency of the estimated monthly savings.

rds_db_recommendations[].instance_recommendation_options[].savings_opportunity_after_discounts.estimated_monthly_savings.value

The value of the estimated monthly savings for Amazon RDS instances.

rds_db_recommendations[].instance_recommendation_options[].savings_opportunity_after_discounts.savings_opportunity_percentage

The estimated monthly savings possible as a percentage of monthly cost by adopting Compute Optimizer’s Amazon RDS instance recommendations. This includes any applicable Savings Plans discounts.

rds_db_recommendations[].last_refresh_timestamp

The timestamp of when the Amazon RDS recommendation was last generated.

rds_db_recommendations[].lookback_period_in_days

The number of days the Amazon RDS utilization metrics were analyzed.

rds_db_recommendations[].resource_arn

The ARN of the current Amazon RDS.

The following is the format of the ARN:

arn:aws:rds:{region}:{accountId}:db:{resourceName}

rds_db_recommendations[].storage_finding

The finding classification of Amazon RDS storage.

Findings for Amazon RDS instance include:

  • Underprovisioned — When Compute Optimizer detects that there’s not enough storage, an Amazon RDS is considered under-provisioned.

  • Overprovisioned — When Compute Optimizer detects that there’s excessive storage, an Amazon RDS is considered over-provisioned.

  • Optimized — When the storage of your Amazon RDS meet the performance requirements of your workload, the service is considered optimized.

rds_db_recommendations[].storage_finding_reason_codes[]
rds_db_recommendations[].storage_recommendation_options[]
Show child fields
rds_db_recommendations[].storage_recommendation_options[].rank

The rank identifier of the RDS storage recommendation option.

rds_db_recommendations[].storage_recommendation_options[].savings_opportunity

Describes the savings opportunity for recommendations of a given resource type or for the recommendation option of an individual resource.

Savings opportunity represents the estimated monthly savings you can achieve by implementing a given Compute Optimizer recommendation.

Savings opportunity data requires that you opt in to Cost Explorer, as well as activate Receive Amazon EC2 resource recommendations in the Cost Explorer preferences page. That creates a connection between Cost Explorer and Compute Optimizer. With this connection, Cost Explorer generates savings estimates considering the price of existing resources, the price of recommended resources, and historical usage data. Estimated monthly savings reflects the projected dollar savings associated with each of the recommendations generated. For more information, see Enabling Cost Explorer and Optimizing your cost with Rightsizing Recommendations in the Cost Management User Guide.

Show child fields
rds_db_recommendations[].storage_recommendation_options[].savings_opportunity.estimated_monthly_savings

An object that describes the estimated monthly savings amount possible by adopting Compute Optimizer recommendations for a given resource. This is based on the On-Demand instance pricing..

Show child fields
rds_db_recommendations[].storage_recommendation_options[].savings_opportunity.estimated_monthly_savings.currency

The currency of the estimated monthly savings.

rds_db_recommendations[].storage_recommendation_options[].savings_opportunity.estimated_monthly_savings.value

The value of the estimated monthly savings.

rds_db_recommendations[].storage_recommendation_options[].savings_opportunity.savings_opportunity_percentage

The estimated monthly savings possible as a percentage of monthly cost by adopting Compute Optimizer recommendations for a given resource.

rds_db_recommendations[].storage_recommendation_options[].savings_opportunity_after_discounts

Describes the savings opportunity for Amazon RDS storage recommendations or for the recommendation option.

Savings opportunity represents the estimated monthly savings after applying Savings Plans discounts. You can achieve this by implementing a given Compute Optimizer recommendation.

Show child fields
rds_db_recommendations[].storage_recommendation_options[].savings_opportunity_after_discounts.estimated_monthly_savings

The estimated monthly savings possible by adopting Compute Optimizer’s Amazon RDS storage recommendations. This includes any applicable Savings Plans discounts.

Show child fields
rds_db_recommendations[].storage_recommendation_options[].savings_opportunity_after_discounts.estimated_monthly_savings.currency

The currency of the estimated monthly savings.

rds_db_recommendations[].storage_recommendation_options[].savings_opportunity_after_discounts.estimated_monthly_savings.value

The value of the estimated monthly savings for Amazon RDS storage.

rds_db_recommendations[].storage_recommendation_options[].savings_opportunity_after_discounts.savings_opportunity_percentage

The estimated monthly savings possible as a percentage of monthly cost by adopting Compute Optimizer’s Amazon RDS storage recommendations. This includes any applicable Savings Plans discounts.

rds_db_recommendations[].storage_recommendation_options[].storage_configuration

The recommended storage configuration.

Show child fields
rds_db_recommendations[].storage_recommendation_options[].storage_configuration.allocated_storage

The size of the RDS storage in gigabytes (GB).

rds_db_recommendations[].storage_recommendation_options[].storage_configuration.iops

The provisioned IOPs of the RDS storage.

rds_db_recommendations[].storage_recommendation_options[].storage_configuration.max_allocated_storage

The maximum limit in gibibytes (GiB) to which Amazon RDS can automatically scale the storage of the RDS instance.

rds_db_recommendations[].storage_recommendation_options[].storage_configuration.storage_throughput

The storage throughput of the RDS storage.

rds_db_recommendations[].storage_recommendation_options[].storage_configuration.storage_type

The type of RDS storage.

rds_db_recommendations[].tags[]
Show child fields
rds_db_recommendations[].tags[].key

One part of a key-value pair that makes up a tag. A key is a general label that acts like a category for more specific tag values.

rds_db_recommendations[].tags[].value

One part of a key-value pair that make up a tag. A value acts as a descriptor within a tag category (key). The value can be empty or null.

rds_db_recommendations[].utilization_metrics[]
Show child fields
rds_db_recommendations[].utilization_metrics[].name

The name of the utilization metric.

rds_db_recommendations[].utilization_metrics[].statistic

The statistic of the utilization metric.

The Compute Optimizer API, Command Line Interface (CLI), and SDKs return utilization metrics using only the Maximum statistic, which is the highest value observed during the specified period.

The Compute Optimizer console displays graphs for some utilization metrics using the Average statistic, which is the value of Sum/SampleCount during the specified period. For more information, see Viewing resource recommendations in the Compute Optimizer User Guide. You can also get averaged utilization metric data for your resources using Amazon CloudWatch. For more information, see the Amazon CloudWatch User Guide.

rds_db_recommendations[].utilization_metrics[].value

The value of the utilization metric.