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

Fix mainloop hang in case job submission fails #349

Conversation

bazsi
Copy link
Member

@bazsi bazsi commented Oct 21, 2024

No description provided.

@alltilla alltilla force-pushed the fix-mainloop-hang-in-case-job-submission-fails branch from b660f7b to de7db68 Compare October 24, 2024 11:46
@alltilla
Copy link
Member

@bazsi
I have extracted the last commit and rebased it to main.
Your previous version can be found here, if we want to revert to it: https://github.com/alltilla/axosyslog/tree/bazsi-fix-mainloop-hang-in-case-job-submission-fails

@@ -573,7 +573,11 @@ log_reader_io_handle_in(gpointer s)
log_reader_disable_watches(self);
if ((self->options->flags & LR_THREADED))
{
main_loop_io_worker_job_submit(&self->io_job, NULL);
if (!main_loop_io_worker_job_submit(&self->io_job, NULL))
Copy link
Member

@MrAnno MrAnno Oct 24, 2024

Choose a reason for hiding this comment

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

This can only fail if main_loop_workers_quit is set, but in that case, we should not retry.

If my assumption is correct, this patch depends on work on a different branch.

Copy link
Member

Choose a reason for hiding this comment

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

That is possible. Talked IRL with Bazsi, and concluded that this PR is meaningful on its own, but I might have misunderstood something. Sorry if so.

Copy link
Member

Choose a reason for hiding this comment

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

We talked about this IRL, registering a task in the debugger would hopefully resolve the issue in a cleaner way.

@bazsi bazsi force-pushed the fix-mainloop-hang-in-case-job-submission-fails branch from de7db68 to 5ba6d4d Compare October 27, 2024 11:30
@bazsi bazsi force-pushed the fix-mainloop-hang-in-case-job-submission-fails branch from 5ba6d4d to 3685e80 Compare October 27, 2024 11:40
@bazsi
Copy link
Member Author

bazsi commented Nov 7, 2024

we could not reproduce the problem and clearly this is not the right solution.

@bazsi bazsi closed this Nov 7, 2024
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.

3 participants