If I explicitly define the source value for a job resource and then later comment out the source attribute then it doesn't revert to the default value. Instead, it's always a no-op.
Configuration
terraform {
required_providers {
databricks = {
source = "databricks/databricks"
"version": "1.40.0"
}
}
}
provider "databricks" {
host = "XXXX"
}
resource "databricks_job" "this" {
name = "fabian_job_debug"
task {
task_key = "python1"
spark_python_task {
python_file = "/Workspace/Shared/test.py"
source = "GIT"
}
job_cluster_key = "job_cluster"
}
task {
task_key = "python2"
spark_python_task {
python_file = "/Workspace/Shared/test.py"
source = "WORKSPACE"
}
job_cluster_key = "job_cluster"
}
task {
task_key = "python3"
spark_python_task {
python_file = "/Workspace/Shared/test.py"
}
job_cluster_key = "job_cluster"
}
job_cluster {
job_cluster_key = "job_cluster"
new_cluster {
autoscale {
min_workers = 1
max_workers = 8
}
node_type_id = "Standard_D3_v2"
spark_version = "13.3.x-scala2.12"
}
}
git_source {
branch = "master"
provider = "awsCodeCommit"
url = "https://git-codecommit.us-west-2.amazonaws.com/v1/repos/TEST_REPO"
}
}
output "url" {
value = databricks_job.this.url
}
Expected Behavior
When I comment out the source attributes then the value for source should be the default (whatever that is).
Actual Behavior
Commenting the source attributes has no effect. The value remains unchanged and Terraform considers this as "no change".
Steps to Reproduce
terraform apply the code above
- Comment our the
source attributes`
terraform apply again
Terraform and provider versions
Terraform v1.5.7
on darwin_arm64
+ provider registry.terraform.io/databricks/databricks v1.40.0
Your version of Terraform is out of date! The latest version
is 1.9.5. You can update by downloading from https://www.terraform.io/downloads.html
Would you like to implement a fix?
no
If I explicitly define the source value for a job resource and then later comment out the
sourceattribute then it doesn't revert to the default value. Instead, it's always a no-op.Configuration
Expected Behavior
When I comment out the
sourceattributes then the value forsourceshould be the default (whatever that is).Actual Behavior
Commenting the
sourceattributes has no effect. The value remains unchanged and Terraform considers this as "no change".Steps to Reproduce
terraform applythe code abovesourceattributes`terraform applyagainTerraform and provider versions
Would you like to implement a fix?
no