Skip to content

Honoring stopasgroup / killasgroup defaulting to false #45

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

Open
m87h opened this issue Jan 12, 2023 · 1 comment
Open

Honoring stopasgroup / killasgroup defaulting to false #45

m87h opened this issue Jan 12, 2023 · 1 comment

Comments

@m87h
Copy link

m87h commented Jan 12, 2023

Thanks for this awesome port. Looking at the main Supervisor docs, stopasgroup and killasgroup default to false. But since this port puts child processes into a job without breakaway, they are in effect always true here if I'm not mistaken?

Related LimitFlags:

  • JOB_OBJECT_LIMIT_SILENT_BREAKAWAY_OK will automatically break away grandchild processes
  • JOB_OBJECT_LIMIT_BREAKAWAY_OK will allow job-aware programs to break away their children on request (using the CREATE_BREAKAWAY_FROM_JOB process creation flag)

Use case: I have an app that spawns an updater process that stops the service and expects to be orphaned. The updater completes the update and the starts the service back up again. But due to the above, the updater gets terminated with the job and the service never restarts. Setting JOB_OBJECT_LIMIT_SILENT_BREAKAWAY_OK in process.py fixes this according to my expectations of stopasgroup and killasgroup.

@alexsilva
Copy link
Owner

I understand the problem and thank you for the detailed explanation.
But due to lack of time a solution for this may take time. If you want, you can advance part of this work by sending a pull request with tests if possible.

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

No branches or pull requests

2 participants