direct: fix apply_policy_default_values drift and for_each_task cluster gaps#5731
Open
denik wants to merge 1 commit into
Open
direct: fix apply_policy_default_values drift and for_each_task cluster gaps#5731denik wants to merge 1 commit into
denik wants to merge 1 commit into
Conversation
The Jobs API accepts apply_policy_default_values in create/update
requests but does not return it in GET responses. The plan engine saw
old=true, new=true, remote=nil and incorrectly scheduled an update.
Fix: add ignore_remote_changes entries with reason not_returned_by_api
for apply_policy_default_values in tasks[*].new_cluster,
tasks[*].for_each_task.task.new_cluster, and job_clusters[*].new_cluster.
Also fill a pre-existing gap: for_each_task inner clusters were missing
backend_defaults entries for enable_elastic_disk, enable_local_disk_encryption,
node_type_id, driver_node_type_id, driver_instance_pool_id, and data_security_mode
(all present for tasks[*].new_cluster and job_clusters[*].new_cluster but not
for the for_each_task path), and ignore_remote_changes for {aws,azure,gcp}_attributes.
Add invariant no_drift test configs for all four affected paths:
- tasks[*].new_cluster.apply_policy_default_values
- tasks[*].for_each_task.task.new_cluster.apply_policy_default_values
- job_clusters[*].new_cluster.apply_policy_default_values
- pipelines.clusters[*].apply_policy_default_values
Update testserver to clear apply_policy_default_values from GET responses,
matching real API behaviour.
Co-authored-by: Isaac
Contributor
Approval status: pending
|
Collaborator
Integration test reportCommit: 91559ea
23 interesting tests: 13 SKIP, 7 KNOWN, 2 flaky, 1 RECOVERED
Top 4 slowest tests (at least 2 minutes):
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
Follow-up to #5693 (which fixed standalone clusters): fix
apply_policy_default_valuesdrift for job/pipeline cluster paths (#5179 (comment)).The Jobs API accepts
apply_policy_default_valuesbut does not return it in GET responses. Addignore_remote_changeswithreason: not_returned_by_apifortasks[*].new_cluster,tasks[*].for_each_task.task.new_cluster, andjob_clusters[*].new_cluster.Also fill a pre-existing gap:
for_each_taskinner clusters were missingbackend_defaults(enable_elastic_disk,enable_local_disk_encryption,node_type_id,driver_node_type_id,driver_instance_pool_id,data_security_mode) andignore_remote_changes({aws,azure,gcp}_attributes) that already existed for the other cluster paths.Tests
New invariant
no_driftconfigs for all four affected paths. Testserver updated to clearapply_policy_default_valuesfrom GET responses, matching real API behavior.