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

Change element type for cluster block to fix issue with phantom blocks in DLT pipeline #1508

Merged
merged 2 commits into from
Aug 2, 2022

Conversation

alexott
Copy link
Contributor

@alexott alexott commented Jul 29, 2022

Current problem reported in #1401 is caused by the behaviour of the complex data types
inside the blocks that use the slice_set as a type - when we make changes the phantom
blocks are generated in addition to required changes. Adding a custom hash function
didn't help.

This PR attempts to fix that issue other way - by changing the type of cluster blocks
from the TypeSet to the TypeList. This approach, besides fixing the original issue
will also help with decreasing the amount of plan changes when making changes in the
cluster block.

The side effect of this change is that when upgrading to a new version, Terraform will
show changes in the DLT pipeline resource even if no actual changes were made in the code -
this is a result of changing the order of the cluster blocks

@alexott alexott requested review from nfx and a team July 29, 2022 10:57
Current problem reported in #1401 is caused by the behaviour of the complex data types
inside the blocks that use the `slice_set` as a type - when we make changes the phantom
blocks are generated in addition to required changes.  Adding a custom hash function
didn't help.

This PR attempts to fix that issue other way - by changing the type of `cluster` blocks
from the `TypeSet` to the `TypeList`.  This approach, besides fixing the original issue
will also help with decreasing the amount of plan changes when making changes in the
`cluster` block.

The side effect of this change is that when upgrading to a new version, Terraform will
show changes in the DLT pipeline resource even if no actual changes were made in the code -
this is a result of changing the order of the `cluster` blocks
@alexott alexott changed the title Second attempt to fix issue with phantom blocks in DLT pipeline Change element type for cluster block to fix issue with phantom blocks in DLT pipeline Aug 1, 2022
@nfx nfx enabled auto-merge (squash) August 2, 2022 08:00
@nfx nfx merged commit 0e69acb into master Aug 2, 2022
@nfx nfx mentioned this pull request Aug 4, 2022
@nkvuong nkvuong deleted the issue-1401-fix-2 branch October 20, 2022 08:37
michael-berk pushed a commit to michael-berk/terraform-provider-databricks that referenced this pull request Feb 15, 2023
)

Current problem reported in databricks#1401 is caused by the behaviour of the complex data types
inside the blocks that use the `slice_set` as a type - when we make changes the phantom
blocks are generated in addition to required changes.  Adding a custom hash function
didn't help.

This PR attempts to fix that issue other way - by changing the type of `cluster` blocks
from the `TypeSet` to the `TypeList`.  This approach, besides fixing the original issue
will also help with decreasing the amount of plan changes when making changes in the
`cluster` block.

The side effect of this change is that when upgrading to a new version, Terraform will
show changes in the DLT pipeline resource even if no actual changes were made in the code -
this is a result of changing the order of the `cluster` blocks
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

Successfully merging this pull request may close these issues.

2 participants