diff --git a/mmv1/products/vertexai/terraform.yaml b/mmv1/products/vertexai/terraform.yaml index 1bc90f894376..ef41c230667d 100644 --- a/mmv1/products/vertexai/terraform.yaml +++ b/mmv1/products/vertexai/terraform.yaml @@ -39,6 +39,8 @@ overrides: !ruby/object:Overrides::ResourceOverrides primary_resource_id: "featurestore" vars: name: "terraform" + ignore_read_extra: + - "force_destroy" properties: region: !ruby/object:Overrides::Terraform::PropertyOverride default_from_api: true diff --git a/mmv1/templates/terraform/examples/vertex_ai_featurestore.tf.erb b/mmv1/templates/terraform/examples/vertex_ai_featurestore.tf.erb index 60a1fdad2051..816cbc2db021 100644 --- a/mmv1/templates/terraform/examples/vertex_ai_featurestore.tf.erb +++ b/mmv1/templates/terraform/examples/vertex_ai_featurestore.tf.erb @@ -8,4 +8,5 @@ resource "google_vertex_ai_featurestore" "featurestore" { online_serving_config { fixed_node_count = 2 } + force_destroy = true } diff --git a/mmv1/templates/terraform/pre_delete/vertex_ai_force_delete.go.erb b/mmv1/templates/terraform/pre_delete/vertex_ai_force_delete.go.erb index adef3161c851..331e3be785eb 100644 --- a/mmv1/templates/terraform/pre_delete/vertex_ai_force_delete.go.erb +++ b/mmv1/templates/terraform/pre_delete/vertex_ai_force_delete.go.erb @@ -1,6 +1,6 @@ if v, ok := d.GetOk("force_destroy"); ok { - url, err = addQueryParams(url, map[string]string{"force": v.(string)}) + url, err = addQueryParams(url, map[string]string{"force": fmt.Sprintf("%v", v)}) if err != nil { return err }