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

daemon: buffer sighup signal #619

Merged
merged 1 commit into from
May 23, 2024
Merged

Conversation

yarda
Copy link
Contributor

@yarda yarda commented Apr 4, 2024

Resolves: RHEL-31180

Resolves: RHEL-31180

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
@yarda yarda requested a review from jmencak April 4, 2024 16:31
@yarda
Copy link
Contributor Author

yarda commented Apr 4, 2024

There is no need for atomic test & set or semaphores, because the signal handler is running in one thread thus the worst thing that could happen is that the SIGHUP on the edge of the time interval will be ignored. Nevertheless, the buffer should improve the responsiveness to the SIGHUP.

@yarda
Copy link
Contributor Author

yarda commented Apr 4, 2024

It would be generally better and much cleaner to do the reloads in the main loop, but it would require bigger code changes.

@jmencak
Copy link
Contributor

jmencak commented Apr 5, 2024

Thank you for a quick fix, @yarda !
LGTM
I've also tested this and I haven't seen TuneD stuck after it was sent a SIGHUP after cca 800 iterations of our e2e test suite.

Copy link
Contributor

@zacikpa zacikpa left a comment

Choose a reason for hiding this comment

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

Thanks, looks good to me.

@yarda yarda merged commit ed472f0 into redhat-performance:master May 23, 2024
16 checks passed
@yarda yarda deleted the sighup-buffer branch May 23, 2024 11:54
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

3 participants