RedisLabs / terraform-provider-rediscloud

Terraform Redis Cloud Provider: Deploy, update, and manage Redis Cloud databases as code through HashiCorp Terraform
https://registry.terraform.io/providers/RedisLabs/rediscloud/latest
Apache License 2.0
29 stars 22 forks source link

Alert name validation on essentials plans is not correct #530

Open dom0Watt opened 2 weeks ago

dom0Watt commented 2 weeks ago

Hi there,

Small issue on version 1.7.0, some validations on supported alert type are not working on rediscloud_essentials_database

Expected Behavior

According to the plan, the supported alerts are: "connections-limit", "throughput-lower-than", "latency", "throughput-higher-than", "datasets-size"

Actual Behavior

when setting an alert with one of the supported types, the validation is not correct: expected name to be one of [dataset-size throughput-higher-than throughput-lower-than latency syncsource-error syncsource-lag], got connections-limit

Steps to Reproduce

Please list the steps required to reproduce the issue, for example:

  1. Declare a rediscloud_essentials_database ressource with alerts
resource "rediscloud_essentials_database" "example" {
...

  alert {
    name  = "connections-limit"
    value = 80
  }
  alert {
    name  = "datasets-size"
    value = 80
  }
}
  1. terraform plan
NoamSternRedis commented 1 week ago

Hi @dom0Watt, thank you for the feedback. We looked into it. Seems like we have an unnecessary validation on the Terraform side. We are pushing a patch version in the next few days. Will update here once it's live.