From 3a35888bde34b0e22ad4f2fdd44573d72acf180b Mon Sep 17 00:00:00 2001 From: The Magician Date: Wed, 8 Mar 2023 14:55:48 -0800 Subject: [PATCH] Fix alloydb_cluster permadiff (#7421) (#13948) Signed-off-by: Modular Magician --- .changelog/7421.txt | 3 +++ google/resource_alloydb_cluster.go | 4 +++- 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 .changelog/7421.txt diff --git a/.changelog/7421.txt b/.changelog/7421.txt new file mode 100644 index 00000000000..20da03b8124 --- /dev/null +++ b/.changelog/7421.txt @@ -0,0 +1,3 @@ +```release-note:bug +alloydb: fix permadiff on `automated_backup_policy.weekly_schedule` of `google_alloydb_cluster` +``` diff --git a/google/resource_alloydb_cluster.go b/google/resource_alloydb_cluster.go index 6ebb316f54a..4b92d26fddf 100644 --- a/google/resource_alloydb_cluster.go +++ b/google/resource_alloydb_cluster.go @@ -58,6 +58,7 @@ func ResourceAlloydbCluster() *schema.Resource { }, "automated_backup_policy": { Type: schema.TypeList, + Computed: true, Optional: true, Description: `The automated backup policy for this cluster. @@ -67,7 +68,8 @@ If no policy is provided then the default policy will be used. The default polic Schema: map[string]*schema.Schema{ "weekly_schedule": { Type: schema.TypeList, - Required: true, + Computed: true, + Optional: true, ForceNew: true, Description: `Weekly schedule for the Backup.`, MaxItems: 1,