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

Agent: sigterm children #36

Merged
merged 5 commits into from
May 3, 2024
Merged

Conversation

remi-espie
Copy link
Contributor

This PR now handle better the signal received by the vmm to gracefully shut down children processes by sending them a sigterm and waiting for them before exiting the process.

More type of signal could be interpreted and sent easily to the children processes.

@remi-espie remi-espie added the enhancement New feature or request label May 1, 2024
@remi-espie remi-espie requested review from mfernd and mmoreiradj May 1, 2024 11:10
@remi-espie remi-espie self-assigned this May 1, 2024
@remi-espie remi-espie force-pushed the feat/sigterm_children branch from ff67591 to 577670e Compare May 1, 2024 11:12
src/agent/src/agents/mod.rs Outdated Show resolved Hide resolved
@remi-espie remi-espie force-pushed the feat/sigterm_children branch 3 times, most recently from b0fe690 to f91d524 Compare May 2, 2024 16:13
remi-espie and others added 5 commits May 3, 2024 12:12
…ception

Signed-off-by: ESPIE <remi.espie@etu.umontpellier.fr>
Signed-off-by: ESPIE <remi.espie@etu.umontpellier.fr>
…be non blocking

Signed-off-by: ESPIE <remi.espie@etu.umontpellier.fr>
Signed-off-by: ESPIE <remi.espie@etu.umontpellier.fr>
Signed-off-by: Mateo Fernandez <mateo.fernandez@etu.umontpellier.fr>
@remi-espie remi-espie force-pushed the feat/sigterm_children branch from 3bfd951 to 4f61ad8 Compare May 3, 2024 10:13
@mfernd mfernd self-requested a review May 3, 2024 15:30
Copy link
Contributor

@mfernd mfernd left a comment

Choose a reason for hiding this comment

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

looks good now!

@mfernd mfernd merged commit 1f46bc7 into virt-do:main May 3, 2024
2 checks passed
MurielParaire pushed a commit to MurielParaire/cloudlet that referenced this pull request May 3, 2024
* feat: child processes are now gracefully sigterm-ed on kill signal reception

Signed-off-by: ESPIE <remi.espie@etu.umontpellier.fr>

* chore: merge from main

Signed-off-by: ESPIE <remi.espie@etu.umontpellier.fr>

* fix: changed `std::process::Command` to `tokio::process::Command` to be non blocking

Signed-off-by: ESPIE <remi.espie@etu.umontpellier.fr>

* chore: cargo fmt

Signed-off-by: ESPIE <remi.espie@etu.umontpellier.fr>

* refactor: use async_trait instead of Pin<Box<Future<>>>

Signed-off-by: Mateo Fernandez <mateo.fernandez@etu.umontpellier.fr>

---------

Signed-off-by: ESPIE <remi.espie@etu.umontpellier.fr>
Signed-off-by: Mateo Fernandez <mateo.fernandez@etu.umontpellier.fr>
Co-authored-by: Mateo Fernandez <mateo.fernandez@etu.umontpellier.fr>
Signed-off-by: Muriel Paraire <72733662+MurielParaire@users.noreply.github.com>
MurielParaire pushed a commit to MurielParaire/cloudlet that referenced this pull request May 3, 2024
* feat: child processes are now gracefully sigterm-ed on kill signal reception

Signed-off-by: ESPIE <remi.espie@etu.umontpellier.fr>

* chore: merge from main

Signed-off-by: ESPIE <remi.espie@etu.umontpellier.fr>

* fix: changed `std::process::Command` to `tokio::process::Command` to be non blocking

Signed-off-by: ESPIE <remi.espie@etu.umontpellier.fr>

* chore: cargo fmt

Signed-off-by: ESPIE <remi.espie@etu.umontpellier.fr>

* refactor: use async_trait instead of Pin<Box<Future<>>>

Signed-off-by: Mateo Fernandez <mateo.fernandez@etu.umontpellier.fr>

---------

Signed-off-by: ESPIE <remi.espie@etu.umontpellier.fr>
Signed-off-by: Mateo Fernandez <mateo.fernandez@etu.umontpellier.fr>
Co-authored-by: Mateo Fernandez <mateo.fernandez@etu.umontpellier.fr>
Signed-off-by: Muriel Paraire <72733662+MurielParaire@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants