Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't restart cluster on changes that doesn't affect it (issue #379) #385

Merged
merged 1 commit into from
Nov 6, 2020
Merged

Don't restart cluster on changes that doesn't affect it (issue #379) #385

merged 1 commit into from
Nov 6, 2020

Conversation

alexott
Copy link
Contributor

@alexott alexott commented Oct 23, 2020

This PR adds detection of what cluster parameters were changed, and call /clusters/edit
only we changed parameters that are related to cluster directly, not things like
is_pinned or library...

This fixes #379

@alexott alexott requested a review from nfx October 23, 2020 14:56
@TravisBuddy
Copy link

Hey @alexott,
Your changes look good to me!

View build log

TravisBuddy Request Identifier: c110c300-1545-11eb-aff7-dd8cbeb067cc

@codecov-io
Copy link

Codecov Report

Merging #385 into master will decrease coverage by 0.02%.
The diff coverage is 66.66%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #385      +/-   ##
==========================================
- Coverage   70.77%   70.75%   -0.03%     
==========================================
  Files          65       65              
  Lines        6542     6554      +12     
==========================================
+ Hits         4630     4637       +7     
- Misses       1477     1482       +5     
  Partials      435      435              
Impacted Files Coverage Δ
compute/resource_cluster.go 74.04% <66.66%> (-0.76%) ⬇️

Copy link
Contributor

@nfx nfx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you add a unit-test?

compute/resource_cluster.go Outdated Show resolved Hide resolved
@alexott
Copy link
Contributor Author

alexott commented Oct 26, 2020

it's interesting question - about unit testing of "incremental" change. I've looked through existing testing infrastructure, and couldn't figure out how to do a "single" change to the existing state - right now you need to provide complete state (with Spark version, etc.), but it will trigger the /clusters/edit as before...

@TravisBuddy
Copy link

Hey @alexott,
Your changes look good to me!

View build log

TravisBuddy Request Identifier: bb5c8140-1f3d-11eb-bd2e-17a8c440c3de

Copy link
Contributor

@nfx nfx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll change it to 0.2.8 :)

@nfx nfx merged commit e3236b5 into databricks:master Nov 6, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[ISSUE] Changing Pinned status causes cluster restart
4 participants