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

global: fix graceful shutdown #526

Merged
merged 1 commit into from
Sep 26, 2023

Conversation

mdonadoni
Copy link
Member

When using the shell form of CMD, the provided command is executed
using /bin/sh -c, which breaks signal propagation. Use exec to
substitute the sh process and fix handling of signals by uwsgi.

Also handle SIGTERM in consume-job-queue to gracefully stop consuming
the job status queue.

Closes reanahub/reana-job-controller#347

@codecov
Copy link

codecov bot commented Sep 21, 2023

Codecov Report

Merging #526 (a2c5baa) into master (d48ef46) will decrease coverage by 0.31%.
The diff coverage is 0.00%.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #526      +/-   ##
==========================================
- Coverage   71.73%   71.42%   -0.31%     
==========================================
  Files          15       15              
  Lines        1394     1400       +6     
==========================================
  Hits         1000     1000              
- Misses        394      400       +6     
Files Changed Coverage Δ
reana_workflow_controller/cli.py 0.00% <0.00%> (ø)

When using the shell form of `CMD`, the provided command is executed
using `/bin/sh -c`, which breaks signal propagation. Use `exec` to
substitute the `sh` process and fix handling of signals by uwsgi.

Also handle SIGTERM in `consume-job-queue` to gracefully stop consuming
the job status queue.

Closes reanahub/reana-job-controller#347
@mdonadoni mdonadoni merged commit a2c5baa into reanahub:master Sep 26, 2023
11 checks passed
@mdonadoni mdonadoni deleted the graceful-shutdown branch September 26, 2023 13:33
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.

job controller doesn't respect graceful shutdown send by k8s
2 participants