Skip to content

Commit 40e4a26

Browse files
authored
Merge pull request #150 from tablexi/va-enable-enhanced-monitoring-on-rds
Enable Enhanced Monitoring for RDS, with a default interval of 60 seconds
2 parents 4273860 + 81a5d28 commit 40e4a26

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

aws/rds/main.tf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ resource "aws_db_instance" "mod" {
5050
iops = var.iops
5151
instance_class = var.node_type
5252
kms_key_id = var.kms_key_id
53+
monitoring_interval = var.monitoring_interval
5354
multi_az = var.multi_az
5455
parameter_group_name = local.parameter_group_name
5556
password = "nopassword"

aws/rds/variables.tf

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,10 @@ variable "env" {
2020

2121
variable "engine" {
2222
description = "Postgres, MySQL, etc."
23-
# default = "postgres"
2423
}
2524

2625
variable "engine_version" {
2726
description = "Version # of the Postgres or MySQL installation. Do not include patch version as it is auto upgraded."
28-
# default = "9.6"
2927
}
3028

3129
variable "identifier" {
@@ -43,6 +41,11 @@ variable "kms_key_id" {
4341
default = ""
4442
}
4543

44+
variable "monitoring_interval" {
45+
default = 60
46+
description = "(Optional) The interval, in seconds, between points when Enhanced Monitoring metrics are collected for the DB instance. To disable collecting Enhanced Monitoring metrics, specify 0. The default is 60. Valid Values: 0, 1, 5, 10, 15, 30, 60."
47+
}
48+
4649
variable "multi_az" {
4750
description = "AWS RDS automatically creates a primary DB Instance and synchronously replicates the data to a standby instance in a different Availability Zone."
4851
default = true

0 commit comments

Comments
 (0)