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

Skip service reload when restart already triggered #11

Merged
merged 1 commit into from
Sep 4, 2024

Conversation

btravouillon
Copy link

Upon changes, some tasks will trigger the reload handler while others will trigger the restart handler. During initial installation of Slurm with the role, this can lead to some race condition where reload and restart will execute too closely one from the other, which can trigger a failure of the second service.

When a restart handler is notified, there should be no need to trigger the reload as well. Move the restart handlers before the reload handlers to make sure those are executed first. Register their result in a variable. Test if the variable is defined in the reload handler (which means that the restart handler was executed).

Also remove one of the 'Reload slurmdbd' handler which was defined twice.

Upon changes, some tasks will trigger the reload handler while others
will trigger the restart handler. During initial installation of Slurm
with the role, this can lead to some race condition where reload and
restart will execute too closely one from the other, which can trigger a
failure of the second service.

When a restart handler is notified, there should be no need to trigger
the reload as well. Move the restart handlers before the reload handlers
to make sure those are executed first. Register their result in a
variable. Test if the variable is defined in the reload handler (which
means that the restart handler was executed).

Also remove one of the 'Reload slurmdbd' handler which was defined
twice.
@btravouillon btravouillon merged commit a59dd8b into mila Sep 4, 2024
1 check passed
@btravouillon btravouillon deleted the fix/race_reload_restart branch September 4, 2024 12:58
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.

3 participants