Skip to content

Allow for in-place update when affinity or spread was changed#25109

Merged
tgross merged 2 commits intohashicorp:mainfrom
pawelbeza:fix-destructive-update-for-affinity-and-spread
Feb 14, 2025
Merged

Allow for in-place update when affinity or spread was changed#25109
tgross merged 2 commits intohashicorp:mainfrom
pawelbeza:fix-destructive-update-for-affinity-and-spread

Conversation

@pawelbeza
Copy link
Copy Markdown
Contributor

@pawelbeza pawelbeza commented Feb 13, 2025

Fixes #25070

Similarly to #6732 it removes checking affinity and spread for inplace update.
Both affinity and spread should be as soft preference for Nomad scheduler rather than strict constraint. Therefore modifying them should not trigger job reallocation.

@pawelbeza pawelbeza requested review from a team as code owners February 13, 2025 11:35
@hashicorp-cla-app
Copy link
Copy Markdown

hashicorp-cla-app Bot commented Feb 13, 2025

CLA assistant check
All committers have signed the CLA.

@hashicorp-cla-app
Copy link
Copy Markdown

CLA assistant check

Thank you for your submission! We require that all contributors sign our Contributor License Agreement ("CLA") before we can accept the contribution. Read and sign the agreement

Learn more about why HashiCorp requires a CLA and what the CLA includes

Have you signed the CLA already but the status is still pending? Recheck it.

Copy link
Copy Markdown
Member

@tgross tgross left a comment

Choose a reason for hiding this comment

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

This looks great @pawelbeza! Thanks!

We've had a discussion internally and have some concerns that folks may be relying on the buggy behavior, even though it wasn't documented either way (Hyrum's Law). So we're going to merge this but hold off on releasing it until the next major version of Nomad (1.10.0 LTS).

I've rebased this PR on main and pushed a commit with some documentation updates. I'll need to pull in another reviewer to merge.

@tgross tgross added this to the 1.10.0 milestone Feb 14, 2025
@aimeeu aimeeu added the theme/docs Documentation issues and enhancements label Feb 14, 2025
Copy link
Copy Markdown
Contributor

@aimeeu aimeeu left a comment

Choose a reason for hiding this comment

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

Thanks Tim for adding the docs!

@tgross tgross merged commit 43885f6 into hashicorp:main Feb 14, 2025
@github-actions
Copy link
Copy Markdown

I'm going to lock this pull request because it has been closed for 120 days ⏳. This helps our maintainers find and focus on the active contributions.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Jun 15, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

theme/docs Documentation issues and enhancements theme/scheduling type/enhancement

Projects

Development

Successfully merging this pull request may close these issues.

Updating affinity in job is destructive

3 participants