Skip to content

Commit

Permalink
Merge pull request #26613 from scottwestover/d-aws_db_instance-update…
Browse files Browse the repository at this point in the history
…d-performance_insights_retention_period

d/aws_db_instance - updated performance insights retention period
  • Loading branch information
ewbankkit authored Sep 6, 2022
2 parents 22ba951 + 42c42c6 commit 3fa99db
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
8 changes: 8 additions & 0 deletions internal/service/rds/instance_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3732,6 +3732,14 @@ func TestAccRDSInstance_performanceInsightsRetentionPeriod(t *testing.T) {
resource.TestCheckResourceAttr(resourceName, "performance_insights_retention_period", "7"),
),
},
{
Config: testAccInstanceConfig_performanceInsightsRetentionPeriod(rName, 155),
Check: resource.ComposeTestCheckFunc(
testAccCheckInstanceExists(resourceName, &dbInstance),
resource.TestCheckResourceAttr(resourceName, "performance_insights_enabled", "true"),
resource.TestCheckResourceAttr(resourceName, "performance_insights_retention_period", "155"),
),
},
},
})
}
Expand Down
2 changes: 1 addition & 1 deletion website/docs/r/db_instance.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ is provided) Password for the master DB user. Note that this may show up in
logs, and it will be stored in the state file.
* `performance_insights_enabled` - (Optional) Specifies whether Performance Insights are enabled. Defaults to false.
* `performance_insights_kms_key_id` - (Optional) The ARN for the KMS key to encrypt Performance Insights data. When specifying `performance_insights_kms_key_id`, `performance_insights_enabled` needs to be set to true. Once KMS key is set, it can never be changed.
* `performance_insights_retention_period` - (Optional) The amount of time in days to retain Performance Insights data. Either 7 (7 days) or 731 (2 years). When specifying `performance_insights_retention_period`, `performance_insights_enabled` needs to be set to true. Defaults to '7'.
* `performance_insights_retention_period` - (Optional) Amount of time in days to retain Performance Insights data. Valid values are `7`, `731` (2 years) or a multiple of `31`. When specifying `performance_insights_retention_period`, `performance_insights_enabled` needs to be set to true. Defaults to '7'.
* `port` - (Optional) The port on which the DB accepts connections.
* `publicly_accessible` - (Optional) Bool to control if instance is publicly
accessible. Default is `false`.
Expand Down
2 changes: 1 addition & 1 deletion website/docs/r/rds_cluster_instance.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ what IAM permissions are needed to allow Enhanced Monitoring for RDS Instances.
* `auto_minor_version_upgrade` - (Optional) Indicates that minor engine upgrades will be applied automatically to the DB instance during the maintenance window. Default `true`.
* `performance_insights_enabled` - (Optional) Specifies whether Performance Insights is enabled or not.
* `performance_insights_kms_key_id` - (Optional) ARN for the KMS key to encrypt Performance Insights data. When specifying `performance_insights_kms_key_id`, `performance_insights_enabled` needs to be set to true.
* `performance_insights_retention_period` - (Optional) Amount of time in days to retain Performance Insights data. Valida values are `7`, `731` (2 years) or a multiple of `31`. When specifying `performance_insights_retention_period`, `performance_insights_enabled` needs to be set to true. Defaults to '7'.
* `performance_insights_retention_period` - (Optional) Amount of time in days to retain Performance Insights data. Valid values are `7`, `731` (2 years) or a multiple of `31`. When specifying `performance_insights_retention_period`, `performance_insights_enabled` needs to be set to true. Defaults to '7'.
* `copy_tags_to_snapshot` – (Optional, boolean) Indicates whether to copy all of the user-defined tags from the DB instance to snapshots of the DB instance. Default `false`.
* `ca_cert_identifier` - (Optional) The identifier of the CA certificate for the DB instance.
* `tags` - (Optional) A map of tags to assign to the instance. If configured with a provider [`default_tags` configuration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags-configuration-block) present, tags with matching keys will overwrite those defined at the provider-level.
Expand Down

0 comments on commit 3fa99db

Please sign in to comment.