Skip to content

Commit

Permalink
Extending schema to include policy ID (#16549)
Browse files Browse the repository at this point in the history
## Summary & Motivation
Retry of [this PR](#16322)
where I think I messed up the git history when I was rebasing master
onto my branch
Policy IDs help enforce what configuration values a cluster is allowed
to have and help enforce consistency across an organization. Enabling
this will allow users to take advantage of this feature.

## How I Tested These Changes
Spun up a local test environment with the changed library installed via
wheel build and ran a test job using the step launcher with a policy ID
attached to the cluster.
  • Loading branch information
zyd14 authored Sep 15, 2023
1 parent 0946311 commit a5d1ef7
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -451,6 +451,11 @@ def _define_new_cluster() -> Field:
),
is_required=False,
)
policy_id = Field(
String,
description="The ID of the cluster policy used to create the cluster if applicable",
is_required=False,
)

return Field(
Shape(
Expand All @@ -466,6 +471,7 @@ def _define_new_cluster() -> Field:
"init_scripts": init_scripts,
"spark_env_vars": spark_env_vars,
"enable_elastic_disk": enable_elastic_disk,
"policy_id": policy_id,
}
)
)
Expand Down

0 comments on commit a5d1ef7

Please sign in to comment.