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

Add logging around certain ways a task can fail #1806

Merged
merged 1 commit into from Jan 14, 2022

Conversation

mdellweg
Copy link
Member

This adds some logging for cases, where the task executing process dies
unexpectedly (e.g. OOM) and is unable to properly set the task state and
error reason.

fixes #9666

@pulpbot
Copy link
Member

pulpbot commented Jan 10, 2022

Attached issue: https://pulp.plan.io/issues/9666

@@ -301,6 +301,21 @@ def supervise_task(self, task):
cancel_reason = "Aborted during worker shutdown."
break
task_process.join()
if not cancel_state and task_process.exitcode != 0:
_logger.info(
Copy link
Member

Choose a reason for hiding this comment

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

What do you think about making this a warning?

Copy link
Member Author

Choose a reason for hiding this comment

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

I can.

This adds some logging for cases, where the task executing process dies
unexpectedly (e.g. OOM) and is unable to properly set the task state and
error reason.

fixes #9666
Copy link
Member

@bmbouter bmbouter left a comment

Choose a reason for hiding this comment

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

This worked great for me. When killing the worker's forked process I received this in the logs: pulpcore.tasking.pulpcore_worker:WARNING: Task process for 05b4e850-fe8d-418e-89bd-7b3c4fce8900 exited with non zero exitcode -9

Thanks!

@bmbouter
Copy link
Member

@awcrosby FYI this change landing on master

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