-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
*: Handle SIGHUP #2139
*: Handle SIGHUP #2139
Conversation
Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com>
Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com>
Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice! Some suggestion. Especially if no one is actually receiving the channel, we might leak some memory (?).
@bwplotka Should I move handling logic per subcommand? or is this good enough? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, that's fine for now. Thanks 👍
* Handle SIGHUP Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com> * Only log when signal received Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com> * Use a buffered channel Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com>
This PR handles received SIGHUP signals and dispatches reload events to sub-commands to handle.
Only the ruler utilizes this right now. Receiver and Ruler implement their own file watchers to reload configurations.
Fixes #1333.
Changes
Verification
make test-local
kill -HUP <thanos-pid>