You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When creating a databricks_connection with Snowflake using PEM private key. Everytime you re-apply the Terraform resource, a change will be detected even though nothing has changed in the Terraform code.
> terraform apply
Terraform used the selected providers to generate the following execution plan. Resource actions are indicated with the following symbols:
+ create
Terraform will perform the following actions:
# databricks_connection.this will be created
+ resource "databricks_connection" "this" {
+ connection_type = "SNOWFLAKE"
+ id = (known after apply)
+ metastore_id = (known after apply)
+ name = "<REDACTED>"
+ options = (sensitive value)
+ owner = (known after apply)
+ read_only = (known after apply)
}
Plan: 1 to add, 0 to change, 0 to destroy.
Do you want to perform these actions?
Terraform will perform the actions described above.
Only 'yes' will be accepted to approve.
Enter a value: yes
databricks_connection.this: Creating...
databricks_connection.this: Creation complete after 1s [id=<REDACTED>|<REDACTED>]
Subsequent run:
> terraform apply
databricks_connection.this: Refreshing state... [id=<REDACTED>|<REDACTED>]
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:
# databricks_connection.this will be updated in-place
~ resource "databricks_connection" "this" {
id = "<REDACTED>"
name = "<REDACTED>"
~ options = (sensitive value)
# (4 unchanged attributes hidden)
}
Plan: 0 to add, 1 to change, 0 to destroy.
Do you want to perform these actions?
Terraform will perform the actions described above.
Only 'yes' will be accepted to approve.
Enter a value:
The reason is because the /api/2.1/unity-catalog/connections/<connection-name> endpoint for a Snowflake connection returns the attribute pem_private_key_expiration_epoch_sec which changes depending on when the plan is executed. Because this changes all the time, it will always be seen as a drift.
Expected Behavior
Subsequent applies for the databricks_connection resource without any changes should not result into drifts.
Actual Behavior
Subsequent applies for the databricks_connection resource result into drifts because of the pem_private_key_expiration_epoch_sec attribute.
Steps to Reproduce
terraform apply
terraform apply (again)
Terraform and provider versions
Terraform v1.7.5
on darwin_arm64
+ provider registry.terraform.io/databricks/databricks v1.64.1
Would you like to implement a fix?
Yes.
The text was updated successfully, but these errors were encountered:
When creating a
databricks_connection
with Snowflake using PEM private key. Everytime you re-apply the Terraform resource, a change will be detected even though nothing has changed in the Terraform code.Configuration
First run:
Subsequent run:
The reason is because the
/api/2.1/unity-catalog/connections/<connection-name>
endpoint for a Snowflake connection returns the attributepem_private_key_expiration_epoch_sec
which changes depending on when the plan is executed. Because this changes all the time, it will always be seen as a drift.Expected Behavior
Subsequent applies for the
databricks_connection
resource without any changes should not result into drifts.Actual Behavior
Subsequent applies for the
databricks_connection
resource result into drifts because of thepem_private_key_expiration_epoch_sec
attribute.Steps to Reproduce
terraform apply
terraform apply
(again)Terraform and provider versions
Would you like to implement a fix?
Yes.
The text was updated successfully, but these errors were encountered: