Skip to content

Commit

Permalink
Merge pull request #76 from Snowflake-Labs/fix-task-auto-suspend
Browse files Browse the repository at this point in the history
Set SUSPEND_TASK_AFTER_NUM_FAILURES parameter to zero on results schema.
  • Loading branch information
sfc-gh-bkou authored May 21, 2024
2 parents 456699a + 9615014 commit 46082ec
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions schemas.tf
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,19 @@ resource "snowflake_schema" "results" {
name = local.results_schema_name
}

resource "snowflake_object_parameter" "results_schema_suspend_task_after_num_failures" {
provider = snowflake.admin_role

key = "SUSPEND_TASK_AFTER_NUM_FAILURES"
value = "0"
object_type = "SCHEMA"

object_identifier {
database = local.snowalert_database_name
name = local.results_schema
}
}

locals {
results_schema = var.create_schemas == true ? snowflake_schema.results[0].name : local.results_schema_name
}
Expand Down

0 comments on commit 46082ec

Please sign in to comment.