diff --git a/cloud/aws/rds/README.md b/cloud/aws/rds/README.md index 36e8780..b6337a1 100644 --- a/cloud/aws/rds/README.md +++ b/cloud/aws/rds/README.md @@ -34,8 +34,6 @@ Inputs | filter_tags_custom | Tags used for custom filtering when filter_tags_use_defaults is false | string | `*` | no | | filter_tags_use_defaults | Use default filter tags convention | string | `true` | no | | message | Message sent when an alert is triggered | string | - | yes | -| notify_no_data | Enable 'No Data' alert | string | `true` | no | -| renotify_interval | The number of minutes after the last notification before a monitor will re-notify on the current status | string | `60` | no | Related documentation --------------------- diff --git a/cloud/aws/rds/inputs.tf b/cloud/aws/rds/inputs.tf index 8e6d89a..cac076f 100644 --- a/cloud/aws/rds/inputs.tf +++ b/cloud/aws/rds/inputs.tf @@ -5,21 +5,11 @@ variable "environment" { } # Global DataDog -variable "notify_no_data" { - description = "Enable 'No Data' alert" - default = true -} - variable "evaluation_delay" { description = "Delay in seconds for the metric evaluation" default = 600 } -variable "renotify_interval" { - description = "The number of minutes after the last notification before a monitor will re-notify on the current status" - default = 60 -} - variable "message" { description = "Message sent when an alert is triggered" } diff --git a/cloud/aws/rds/monitors-rds.tf b/cloud/aws/rds/monitors-rds.tf index bb83b46..dffb178 100644 --- a/cloud/aws/rds/monitors-rds.tf +++ b/cloud/aws/rds/monitors-rds.tf @@ -8,10 +8,11 @@ data "template_file" "filter" { ### RDS instance CPU monitor ### resource "datadog_monitor" "rds_cpu_90_15min" { - name = "[${var.environment}] RDS instance CPU high > ${var.cpu_threshold_critical}% for 15 min on {{host.identifier}}" + name = "[${var.environment}] RDS instance CPU high {{comparator}} {{#is_alert}}{{threshold}}%{{/is_alert}}{{#is_warning}}{{warn_threshold}}%{{/is_warning}} ({{value}}%)" message = "${var.message}" - type = "metric alert" + type = "metric alert" + query = <