File tree Expand file tree Collapse file tree 2 files changed +16
-0
lines changed Expand file tree Collapse file tree 2 files changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -65,6 +65,10 @@ resource "aws_db_instance" "rds_postgres" {
65
65
copy_tags_to_snapshot = var. copy_tags_to_snapshot
66
66
tags = local. effective_tags
67
67
68
+ # Performance Insights
69
+ performance_insights_enabled = var. performance_insights_enabled
70
+ performance_insights_retention_period = var. performance_insights_enabled ? var. performance_insights_retention_period : null
71
+
68
72
lifecycle {
69
73
ignore_changes = [password ]
70
74
}
Original file line number Diff line number Diff line change @@ -161,3 +161,15 @@ variable "multi_az" {
161
161
type = bool
162
162
description = " Specifies if the RDS instance is multi-AZ."
163
163
}
164
+
165
+ variable "performance_insights_enabled" {
166
+ default = false
167
+ type = bool
168
+ description = " Specifies whether Performance Insights are enabled."
169
+ }
170
+
171
+ variable "performance_insights_retention_period" {
172
+ default = 7
173
+ type = number
174
+ description = " The amount of time in days to retain Performance Insights data. Either 7 (7 days) or 731 (2 years)."
175
+ }
You can’t perform that action at this time.
0 commit comments