diff --git a/third_party/terraform/resources/resource_bigtable_gc_policy.go b/third_party/terraform/resources/resource_bigtable_gc_policy.go index 1a440268ce31..bc81d5f1bd69 100644 --- a/third_party/terraform/resources/resource_bigtable_gc_policy.go +++ b/third_party/terraform/resources/resource_bigtable_gc_policy.go @@ -58,6 +58,7 @@ func resourceBigtableGCPolicy() *schema.Resource { Optional: true, ForceNew: true, Description: `GC policy that applies to all cells older than the given age.`, + MaxItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "days": { @@ -89,7 +90,6 @@ func resourceBigtableGCPolicy() *schema.Resource { Type: schema.TypeInt, Required: true, Description: `Number of version before applying the GC policy.`, - ValidateFunc: validation.IntAtLeast(1), }, }, }, diff --git a/third_party/terraform/website/docs/r/bigtable_gc_policy.html.markdown b/third_party/terraform/website/docs/r/bigtable_gc_policy.html.markdown index 8454cb71415d..7c6ff3c237cd 100644 --- a/third_party/terraform/website/docs/r/bigtable_gc_policy.html.markdown +++ b/third_party/terraform/website/docs/r/bigtable_gc_policy.html.markdown @@ -42,7 +42,7 @@ resource "google_bigtable_gc_policy" "policy" { column_family = "name" max_age { - duration = "168h" # 7 days + duration = "168h" } } ``` @@ -89,9 +89,9 @@ The following arguments are supported: `max_age` supports the following arguments: -* `days` - (Deprecated) Number of days before applying GC policy. +* `days` - (Optional, Deprecated in favor of duration) Number of days before applying GC policy. -* `duration` - (Required) Duration before applying GC policy (ex. "8h"). This is required when `days` isn't set +* `duration` - (Optional) Duration before applying GC policy (ex. "8h"). This is required when `days` isn't set -----