From 4eff3963110f5d8b4be359534d93b85ca1140642 Mon Sep 17 00:00:00 2001 From: Brad Swenson Date: Thu, 24 Mar 2022 18:54:42 -0500 Subject: [PATCH 1/3] add healthcheck notification deprecation --- cloudflare/schema_cloudflare_healthcheck.go | 8 +++++--- website/docs/r/healthcheck.html.markdown | 4 ++-- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/cloudflare/schema_cloudflare_healthcheck.go b/cloudflare/schema_cloudflare_healthcheck.go index 16660e9628..c65cec95ef 100644 --- a/cloudflare/schema_cloudflare_healthcheck.go +++ b/cloudflare/schema_cloudflare_healthcheck.go @@ -126,9 +126,10 @@ func resourceCloudflareHealthcheckSchema() map[string]*schema.Schema { }, }, "notification_suspended": { - Type: schema.TypeBool, - Optional: true, - Default: false, + Type: schema.TypeBool, + Optional: true, + Default: false, + Deprecated: "deprecated in favor of using `cloudflare_notification_policy` instead.", }, "notification_email_addresses": { Type: schema.TypeList, @@ -136,6 +137,7 @@ func resourceCloudflareHealthcheckSchema() map[string]*schema.Schema { Elem: &schema.Schema{ Type: schema.TypeString, }, + Deprecated: "deprecated in favor of using `cloudflare_notification_policy` instead.", }, "created_on": { Type: schema.TypeString, diff --git a/website/docs/r/healthcheck.html.markdown b/website/docs/r/healthcheck.html.markdown index 82e0e0f462..1c7388adf4 100644 --- a/website/docs/r/healthcheck.html.markdown +++ b/website/docs/r/healthcheck.html.markdown @@ -92,8 +92,8 @@ The following arguments are supported: * `address` - (Required) The hostname or IP address of the origin server to run health checks on. * `suspended` - (Optional) If suspended, no health checks are sent to the origin. Valid values: `true` or `false` (Default: `false`). * `check_regions` - (Optional) A list of regions from which to run health checks. If not set Cloudflare will pick a default region. Valid values: `WNAM`, `ENAM`, `WEU`, `EEU`, `NSAM`, `SSAM`, `OC`, `ME`, `NAF`, `SAF`, `IN`, `SEAS`, `NEAS`, `ALL_REGIONS`. -* `notification_suspended` - (Optional) Whether the notifications are suspended or not. Useful for maintenance periods. Valid values: `true` or `false` (Default: `false`). -* `notification_email_addresses` - (Optional) A list of email addresses we want to send the notifications to. +* `notification_suspended` - (Optional) Whether the notifications are suspended or not. Useful for maintenance periods. Valid values: `true` or `false` (Default: `false`). *Deprecated, use `cloudflare_notification_policy` instead.* +* `notification_email_addresses` - (Optional) A list of email addresses we want to send the notifications to. *Deprecated, use `cloudflare_notification_policy` instead.* * `type` - (Required) The protocol to use for the health check. Valid values: `HTTP`, `HTTPS`, `TCP`. * `port` - (Optional) Port number to connect to for the health check. Valid values are in the range `0-65535` (Default: `80`). * `timeout` - (Optional) The timeout (in seconds) before marking the health check as failed. (Default: `5`) From 1787d8ef2a271b17565638f13b71ff2dd3010287 Mon Sep 17 00:00:00 2001 From: Brad Swenson Date: Fri, 25 Mar 2022 13:44:25 -0500 Subject: [PATCH 2/3] add changelog --- .changelog/1529.txt | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 .changelog/1529.txt diff --git a/.changelog/1529.txt b/.changelog/1529.txt new file mode 100644 index 0000000000..71c42852fe --- /dev/null +++ b/.changelog/1529.txt @@ -0,0 +1,3 @@ +```release-note:note +resource/cloudflare_healthcheck: notification_suspended and notification_email_addresses attributes are being deprecated in favor of cloudflare_notification_policy resource. +``` \ No newline at end of file From 467f43277ad48edf7d8220d914c5ceec09505977 Mon Sep 17 00:00:00 2001 From: Jacob Bednarz Date: Sun, 27 Mar 2022 07:00:35 +1100 Subject: [PATCH 3/3] update deprecation wording --- .changelog/1529.txt | 2 +- cloudflare/schema_cloudflare_healthcheck.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.changelog/1529.txt b/.changelog/1529.txt index 71c42852fe..7e55a72728 100644 --- a/.changelog/1529.txt +++ b/.changelog/1529.txt @@ -1,3 +1,3 @@ ```release-note:note -resource/cloudflare_healthcheck: notification_suspended and notification_email_addresses attributes are being deprecated in favor of cloudflare_notification_policy resource. +resource/cloudflare_healthcheck: `notification_suspended` and `notification_email_addresses` attributes are being deprecated in favour of `cloudflare_notification_policy` resource instead. ``` \ No newline at end of file diff --git a/cloudflare/schema_cloudflare_healthcheck.go b/cloudflare/schema_cloudflare_healthcheck.go index c65cec95ef..4e22ac099e 100644 --- a/cloudflare/schema_cloudflare_healthcheck.go +++ b/cloudflare/schema_cloudflare_healthcheck.go @@ -129,7 +129,7 @@ func resourceCloudflareHealthcheckSchema() map[string]*schema.Schema { Type: schema.TypeBool, Optional: true, Default: false, - Deprecated: "deprecated in favor of using `cloudflare_notification_policy` instead.", + Deprecated: "Use `cloudflare_notification_policy` instead.", }, "notification_email_addresses": { Type: schema.TypeList, @@ -137,7 +137,7 @@ func resourceCloudflareHealthcheckSchema() map[string]*schema.Schema { Elem: &schema.Schema{ Type: schema.TypeString, }, - Deprecated: "deprecated in favor of using `cloudflare_notification_policy` instead.", + Deprecated: "Use `cloudflare_notification_policy` instead.", }, "created_on": { Type: schema.TypeString,