Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unable to set variable threshold_microseconds in coralogix_slo #305

Open
papaya-daniel opened this issue Jan 12, 2025 · 1 comment
Open

Comments

@papaya-daniel
Copy link

Affected Resource(s)

  • coralogix_slo

Terraform Configuration Files

terraform {
  required_providers {
    coralogix = {
      version = "~> 2.0"
      source  = "coralogix/coralogix"
    }
  }
}

provider "coralogix" {
  #api_key = "<add your api key here or add env variable CORALOGIX_API_KEY>"
  env     = "EUROPE1"
}

variable dummy {
  type        = number
  default     = 100000
}

resource "coralogix_slo" "example_2" {
  name            = "coralogix_slo_example"
  service_name    = "service_name"
  description     = "description"
  target_percentage = 30
  type            = "latency"
  threshold_microseconds = var.dummy
  threshold_symbol_type = "greater"
  period          = "7_days"
  filters = [
    {
      field = "severity"
      compare_type = "is"
      field_values = ["error", "warning"]
    },
  ]
}

Debug Output

https://gist.github.com/papaya-daniel/2ade034bdca171c073e18868df03747c

Panic Output

Expected Behavior

a plan for coralogix_slo of type latency with 100000 threshold_microseconds

Actual Behavior

│ Error: ThresholdMicroseconds is required when type is latency

│ with coralogix_slo.example_2,
│ on main.tf line 26, in resource "coralogix_slo" "example_2":
│ 26: resource "coralogix_slo" "example_2" {

│ ThresholdMicroseconds is required when type is latency

Steps to Reproduce

  1. terraform plan

Important Factoids

nothing atypical about the accounts

References

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment
@celaus
Copy link
Collaborator

celaus commented Jan 13, 2025

fixed in #304
😄 sorry for that

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants