Skip to content

Fix unknown before apply warnings for namespace endpoints #357

@bechols

Description

@bechols

Currently, when updating retention on a namespace, the namespace endpoints are marked "known after apply":

# temporalcloud_namespace.foo-terraform will be updated in-place
  ~ resource "temporalcloud_namespace" "foo-terraform" {
      ~ endpoints      = {
          ~ grpc_address      = "us-east-1.aws.api.temporal.io:7233" -> (known after apply)
          + mtls_grpc_address = (known after apply)
          ~ web_address       = "https://foo-terraform.abc12.web.tmprl.cloud/" -> (known after apply)
        } -> (known after apply)
        id             = "foo-terraform.abc12"
        name           = "foo-terraform"
      ~ retention_days = 1 -> 2
        # (2 unchanged attributes hidden)
    }

Plan: 0 to add, 1 to change, 0 to destroy.

Do you want to perform these actions?

This creates concern that the endpoints could change and thus break clients. These endpoints aren't actually editable, but the current experience is confusing/worrying.

We believe this will fix it:

	PlanModifiers: []planmodifier.String{
					stringplanmodifier.UseStateForUnknown(),
				},

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions