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

systemd: use SIGUSR2 for shutdown, for LDM #4603

Merged
merged 1 commit into from Sep 28, 2023

Conversation

philpennock
Copy link
Member

Changes proposed in this pull request:

  • tell systemd to use SIGUSR2 for shutdown, to trigger Lame Duck Mode in nats-server

@philpennock philpennock requested a review from a team as a code owner September 28, 2023 17:18
Copy link
Member

@derekcollison derekcollison left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - Question should we leave commented out though? This would change behavior yes?

@philpennock
Copy link
Member Author

philpennock commented Sep 28, 2023

Someone would have to actually use this util/ script config-file from the repo, as-is, automatically deploying it. Do such setups exist? AFAIK this is just a source for people to copy from during setup, if they so choose.

@philpennock philpennock merged commit 259e904 into main Sep 28, 2023
2 checks passed
@philpennock philpennock deleted the pdp/systemd-example-units-lameduck branch September 28, 2023 18:26
@derekcollison
Copy link
Member

Oh yes they do. Without any edits.

Comment on lines 9 to +14
ExecStop=/bin/kill -s SIGINT $MAINPID
User=nats
Group=nats
# The nats-server uses SIGUSR2 to trigger using Lame Duck Mode (LDM) shutdown
KillSignal=SIGUSR2
# You might want to adjust TimeoutStopSec too.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hello, sorry for the late message, I only saw the change when browsing the release notes.

Shouldn't the ExecStop command also be updated to send SIGUSR2 ?

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.

None yet

4 participants