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

confluent_schema resource updates because “whitespace changes” but nothing has changed #573

Open
NickDub opened this issue Feb 25, 2025 · 4 comments
Labels
bug Something isn't working duplicate This issue or pull request already exists

Comments

@NickDub
Copy link

NickDub commented Feb 25, 2025

We haven't made any changes to our resources, but, from v2.16.0, when we plan/apply, we get the following message :

Terraform used the selected providers to generate the following execution
plan. Resource actions are indicated with the following symbols:
~ update in-place
Terraform will perform the following actions:
   # module.common_module.confluent_schema.kafka_schema[my-schema-key] will be updated in-place
~ resource confluent_schema kafka_schema
      id = my-schema-key/latest
    ~ schema = jsonencode( # whitespace changes
                  fields = [
                          name = code
                           type = string
                       ,
                   ]
                   name = Key
                   namespace = myNamespace
                   type = record
      )
      # (7 unchanged attributes hidden)

We don't know where the “whitespace changes” come from. But it takes a long time to plan/apply, even though there's no change.

@linouk23
Copy link
Contributor

@NickDub thanks for creating this issue! Could you share your

  • TF Provider for Confluent version
  • Terraform version
  • The exact schema so we could reproduce this issue

@linouk23 linouk23 added the bug Something isn't working label Feb 25, 2025
@NickDub
Copy link
Author

NickDub commented Feb 26, 2025

@linouk23

  • TF Provider for Confluent version : we're using the latest, but the issue only appeared after v2.15.0
  • Terraform version : v1.9.8
  • The exact schema :
{
  "namespace": "com.orga.NameSpace",
  "name": "EnrichmentKey",
  "type": "record",
  "fields": [
    {
      "name": "code",
      "type": "string"
    }
  ]
}

@linouk23
Copy link
Contributor

linouk23 commented Mar 4, 2025

@NickDub thanks for sharing this example!

Let me try to reproduce the issue by creating this schema using v1.83.0 version of TF Provider, then update to v2.1.0, v2.5.0, v2.15.0, v2.16.0, and then finally update to v2.18.0.

For context, v1.83.0 and v.2.1.0 were copied from #436.

@linouk23
Copy link
Contributor

linouk23 commented Mar 4, 2025

@NickDub could you share what version of TF Provider were you using when creating this schema?

I'm not sure whether it helps, but here's what we recently received from one of the users who reported a similar issue:

The issue was observed with the Confluent Terraform provider version 2.5.0. Upgrading to version 2.17.0 resolved it, and evidence suggests the fix was introduced in version 2.6.0. This appears to no longer be a concern and the matter can be considered resolved.

@linouk23 linouk23 added the duplicate This issue or pull request already exists label Mar 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

2 participants