MON-92 - Hardcode threshold
This commit is contained in:
parent
e383e800d0
commit
98c03062fd
@ -79,4 +79,3 @@ 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 |
|
||||
| replica_status_critical | The ReplicaSet status is DOWN | string | `0` | no |
|
||||
|
||||
@ -23,9 +23,3 @@ variable "filter_tags_custom" {
|
||||
description = "Tags used for custom filtering when filter_tags_use_defaults is false"
|
||||
default = "*"
|
||||
}
|
||||
|
||||
##MongoDB
|
||||
variable "replica_status_critical" {
|
||||
description = "The ReplicaSet status is DOWN"
|
||||
default = 0
|
||||
}
|
||||
|
||||
@ -13,15 +13,11 @@ resource "datadog_monitor" "mongodb_replicaset_state" {
|
||||
query = <<EOF
|
||||
avg(last_5m): (
|
||||
avg:mongodb.replset.health{${data.template_file.filter.rendered}} by {region,replset_name}
|
||||
) == ${var.replica_status_critical}
|
||||
) == 0
|
||||
EOF
|
||||
|
||||
type = "metric alert"
|
||||
|
||||
thresholds {
|
||||
critical = "${var.replica_status_critical}"
|
||||
}
|
||||
|
||||
notify_no_data = true
|
||||
renotify_interval = 0
|
||||
evaluation_delay = "${var.evaluation_delay}"
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user