fix closing resources for azure storage monitors (#7)

This commit is contained in:
Quentin Manfroi 2021-06-25 11:33:40 +02:00 committed by GitHub
parent c3f050f9dc
commit 89102fbb1f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -28,7 +28,6 @@ EOQ
tags = concat(["env:${var.environment}", "type:cloud", "provider:azure", "resource:storage", "team:claranet", "created-by:terraform"], var.status_extra_tags)
}
resource "datadog_monitor" "blobservices_requests_error" {
count = var.successful_requests_enabled == "true" ? 1 : 0
name = "${var.prefix_slug == "" ? "" : "[${var.prefix_slug}]"}[${var.environment}] Azure Storage Blob service too few successful requests {{#is_alert}}{{{comparator}}} {{threshold}}% ({{value}}%){{/is_alert}}{{#is_warning}}{{{comparator}}} {{warn_threshold}}% ({{value}}%){{/is_warning}}"
@ -227,8 +226,8 @@ EOQ
evaluation_delay = var.evaluation_delay
renotify_interval = 0
tags = concat(["env:${var.environment}", "type:cloud", "provider:azure", "resource:storage", "team:claranet", "created-by:terraform"], var.latency_extra_tags)
}
resource "datadog_monitor" "queueservices_latency" {
count = var.latency_enabled == "true" ? 1 : 0
@ -260,8 +259,8 @@ EOQ
evaluation_delay = var.evaluation_delay
renotify_interval = 0
tags = concat(["env:${var.environment}", "type:cloud", "provider:azure", "resource:storage", "team:claranet", "created-by:terraform"], var.latency_extra_tags)
}
resource "datadog_monitor" "tableservices_latency" {
count = var.latency_enabled == "true" ? 1 : 0
@ -293,8 +292,8 @@ EOQ
evaluation_delay = var.evaluation_delay
renotify_interval = 0
tags = concat(["env:${var.environment}", "type:cloud", "provider:azure", "resource:storage", "team:claranet", "created-by:terraform"], var.latency_extra_tags)
}
resource "datadog_monitor" "blob_timeout_error_requests" {
count = var.timeout_error_requests_enabled == "true" ? 1 : 0
@ -529,8 +528,8 @@ EOQ
evaluation_delay = var.evaluation_delay
renotify_interval = 0
tags = concat(["env:${var.environment}", "type:cloud", "provider:azure", "resource:storage", "team:claranet", "created-by:terraform"], var.network_error_requests_extra_tags)
}
resource "datadog_monitor" "table_network_error_requests" {
count = var.network_error_requests_enabled == "true" ? 1 : 0
@ -597,8 +596,8 @@ EOQ
evaluation_delay = var.evaluation_delay
renotify_interval = 0
tags = concat(["env:${var.environment}", "type:cloud", "provider:azure", "resource:storage", "team:claranet", "created-by:terraform"], var.throttling_error_requests_extra_tags)
}
resource "datadog_monitor" "file_throttling_error_requests" {
count = var.throttling_error_requests_enabled == "true" ? 1 : 0
@ -632,6 +631,7 @@ EOQ
renotify_interval = 0
tags = concat(["env:${var.environment}", "type:cloud", "provider:azure", "resource:storage", "team:claranet", "created-by:terraform"], var.throttling_error_requests_extra_tags)
}
resource "datadog_monitor" "queue_throttling_error_requests" {
count = var.throttling_error_requests_enabled == "true" ? 1 : 0
@ -701,8 +701,6 @@ EOQ
tags = concat(["env:${var.environment}", "type:cloud", "provider:azure", "resource:storage", "team:claranet", "created-by:terraform"], var.throttling_error_requests_extra_tags)
}
resource "datadog_monitor" "blob_server_other_error_requests" {
count = var.server_other_error_requests_enabled == "true" ? 1 : 0
name = "${var.prefix_slug == "" ? "" : "[${var.prefix_slug}]"}[${var.environment}] Azure Blob Storage too many server_other errors {{#is_alert}}{{{comparator}}} {{threshold}}% ({{value}}%){{/is_alert}}{{#is_warning}}{{{comparator}}} {{warn_threshold}}% ({{value}}%){{/is_warning}}"
@ -802,8 +800,8 @@ EOQ
evaluation_delay = var.evaluation_delay
renotify_interval = 0
tags = concat(["env:${var.environment}", "type:cloud", "provider:azure", "resource:storage", "team:claranet", "created-by:terraform"], var.server_other_error_requests_extra_tags)
}
resource "datadog_monitor" "table_server_other_error_requests" {
count = var.server_other_error_requests_enabled == "true" ? 1 : 0
@ -937,8 +935,8 @@ EOQ
evaluation_delay = var.evaluation_delay
renotify_interval = 0
tags = concat(["env:${var.environment}", "type:cloud", "provider:azure", "resource:storage", "team:claranet", "created-by:terraform"], var.client_other_error_requests_extra_tags)
}
resource "datadog_monitor" "table_client_other_error_requests" {
count = var.client_other_error_requests_enabled == "true" ? 1 : 0
@ -1039,8 +1037,8 @@ EOQ
evaluation_delay = var.evaluation_delay
renotify_interval = 0
tags = concat(["env:${var.environment}", "type:cloud", "provider:azure", "resource:storage", "team:claranet", "created-by:terraform"], var.authorization_error_requests_extra_tags)
}
resource "datadog_monitor" "queue_authorization_error_requests" {
count = var.authorization_error_requests_enabled == "true" ? 1 : 0