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

job_endpoint: check spec for all regions #14519

Merged
merged 2 commits into from
Sep 12, 2022

Conversation

DerekStrickland
Copy link
Contributor

This PR introduces a helper method to the Job RPC endpoint called specChanged. This method checks whether an incoming jobspec has changed relative to the currently deployed jobspec in all regions. This handles the case where a job has been stopped in one or more regions, and the operator now wants to restart it. By checking all regions, the spec change is detected, and a new job version can be computed and deployed to all multiregion targets.

@DerekStrickland DerekStrickland added backport/1.1.x backport to 1.1.x release line backport/1.2.x backport to 1.1.x release line backport/1.3.x backport to 1.3.x release line labels Sep 9, 2022
@DerekStrickland DerekStrickland added this to the 1.4.0 milestone Sep 9, 2022
@DerekStrickland DerekStrickland self-assigned this Sep 9, 2022
Copy link
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.

I think the overall approach here is sound @DerekStrickland

nomad/job_endpoint.go Outdated Show resolved Hide resolved
nomad/job_endpoint.go Outdated Show resolved Hide resolved
nomad/job_endpoint.go Outdated Show resolved Hide resolved
nomad/job_endpoint.go Outdated Show resolved Hide resolved
nomad/job_endpoint.go Outdated Show resolved Hide resolved
nomad/job_endpoint.go Outdated Show resolved Hide resolved
nomad/job_endpoint.go Outdated Show resolved Hide resolved
Copy link
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.

LGTM!

@DerekStrickland DerekStrickland merged commit 6bca91e into main Sep 12, 2022
@DerekStrickland DerekStrickland deleted the b-multiregion-spec-changed branch September 12, 2022 13:24
DerekStrickland added a commit that referenced this pull request Sep 12, 2022
* job_endpoint: check spec for all regions
DerekStrickland added a commit that referenced this pull request Sep 12, 2022
* job_endpoint: check spec for all regions

Co-authored-by: Derek Strickland <1111455+DerekStrickland@users.noreply.github.com>
@github-actions
Copy link

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 Jan 11, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
backport/1.1.x backport to 1.1.x release line backport/1.2.x backport to 1.1.x release line backport/1.3.x backport to 1.3.x release line
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants