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
[do not review] WIP: graceful plugin shutdown #13760
Closed
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Changelog[uncommitted] (2023-08-25) |
abhinav
added
ci/test
Test CI pipelines on this PR
impact/no-changelog-required
This issue doesn't require a CHANGELOG update
do-not-merge
labels
Aug 23, 2023
abhinav
force-pushed
the
abhinav/graceful-shutdown
branch
5 times, most recently
from
August 23, 2023 18:21
411c924
to
10d08ff
Compare
abhinav
force-pushed
the
abhinav/graceful-shutdown
branch
11 times, most recently
from
August 25, 2023 16:32
6841e19
to
2a2ff3f
Compare
Excellent! CREATE_NEW_PROCESS_GROUP propagates signals to child processes similar to |
abhinav
force-pushed
the
abhinav/graceful-shutdown
branch
3 times, most recently
from
August 25, 2023 19:46
250afee
to
29d15e9
Compare
Disable all other tests in CI except the ones being experimented with to test on Windows more easily.
Pending: children
These functions are now process-group scoped.
abhinav
force-pushed
the
abhinav/graceful-shutdown
branch
from
August 25, 2023 20:54
29d15e9
to
93dd8f6
Compare
abhinav
force-pushed
the
abhinav/graceful-shutdown
branch
from
August 25, 2023 22:34
58792f2
to
30900a5
Compare
abhinav
force-pushed
the
abhinav/graceful-shutdown
branch
from
August 25, 2023 22:39
30900a5
to
b8e878a
Compare
abhinav
force-pushed
the
abhinav/graceful-shutdown
branch
from
August 25, 2023 23:00
bfd9092
to
f95c85c
Compare
GREEN! Excellent, I'll pull this stuff into a real PR now. |
abhinav
added a commit
that referenced
this pull request
Aug 25, 2023
Adds a new **currently unused** function TerminateProcessGroup that terminates all processes in a group gracefully. It does so by first sending the process a SIGINT on Unix systems, and CTRL_BREAK_EVENT on Windows, and waiting a specified duration for the process to exit. The choice of signals was very deliberate and is documented in the comments for TerminateProcessGroup. If the process does not exit in the given duration, it and its child processes are forcibly terminated with SIGKILL or equivalent. Testing: The core behaviors are tested against Python, Go, and Node. The corner cases of signal handling are tested against rogue Go processes. The changes were experimented with in #13760. Refs #9780
abhinav
added a commit
that referenced
this pull request
Aug 26, 2023
Adds a new **currently unused** function TerminateProcessGroup that terminates all processes in a group gracefully. It does so by first sending the process a SIGINT on Unix systems, and CTRL_BREAK_EVENT on Windows, and waiting a specified duration for the process to exit. The choice of signals was very deliberate and is documented in the comments for TerminateProcessGroup. If the process does not exit in the given duration, it and its child processes are forcibly terminated with SIGKILL or equivalent. Testing: The core behaviors are tested against Python, Go, and Node. The corner cases of signal handling are tested against rogue Go processes. The changes were experimented with in #13760. Refs #9780
github-merge-queue bot
pushed a commit
that referenced
this pull request
Aug 27, 2023
Adds a new **currently unused** function TerminateProcessGroup that terminates all processes in a group gracefully. It does so by first sending the process a SIGINT on Unix systems, and CTRL_BREAK_EVENT on Windows, and waiting a specified duration for the process to exit. The choice of signals was very deliberate and is documented in the comments for TerminateProcessGroup. If the process does not exit in the given duration, it and its child processes are forcibly terminated with SIGKILL or equivalent. Testing: The core behaviors are tested against Python, Go, and Node. The corner cases of signal handling are tested against rogue Go processes. The changes were experimented with in #13760. Refs #9780
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Do not review yet
This is just to experiment with graceful shutdown of plugins.