Skip to content

[Messenger] Add messenger.stop_worker_on_signals option documentation #18105

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

Merged
merged 1 commit into from
Mar 21, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions messenger.rst
Original file line number Diff line number Diff line change
Expand Up @@ -757,8 +757,12 @@ Graceful Shutdown
.................

If you install the `PCNTL`_ PHP extension in your project, workers will handle
the ``SIGTERM`` POSIX signal to finish processing their current message before
terminating.
the ``SIGTERM`` or ``SIGINT`` POSIX signals to finish processing their current
message before terminating.

However, you might prefer to use different POSIX signals for graceful shutdown.
You can override default ones by setting ``framework.messenger.stop_worker_on_signals``
configuration option.

In some cases the ``SIGTERM`` signal is sent by Supervisor itself (e.g. stopping
a Docker container having Supervisor as its entrypoint). In these cases you
Expand Down