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

Introduce a Stopping state #3483

Draft
wants to merge 49 commits into
base: add-force-stop
Choose a base branch
from
Draft

Introduce a Stopping state #3483

wants to merge 49 commits into from

Conversation

ricab
Copy link
Collaborator

@ricab ricab commented Apr 12, 2024

No description provided.

luis4a0 and others added 30 commits April 12, 2024 13:59
This will make it explicit that the user wants to force stop an
instance.
Change "Forced" to "Forcing"

Co-authored-by: Ricardo Abreu <6698114+ricab@users.noreply.github.com>
Signed-off-by: Chris Townsend <christopher.townsend@canonical.com>
Drop the SSH session from LXD VMs when the stopping state is detected.
Handle the new stopping state, along with other states, when ensuring
that a LXD VM is running.
Deal with cases where we read multiple QMP entries in a single read of
QEMU's output. This is motivated mainly by the POWERDOWN event coming
together with a "return" entry (right after it) when stopping a VM.
Issue a warning when reading QMP output outside of newline boundaries,
which the code is otherwise unable to handle, as it would most likely
result in bad JSON on the corresponding and following reads.
@ricab ricab force-pushed the add-stopping-state branch 2 times, most recently from ba362ce to 6d6548e Compare April 15, 2024 11:40
Copy link

codecov bot commented Apr 15, 2024

Codecov Report

Attention: Patch coverage is 56.30252% with 52 lines in your changes are missing coverage. Please review.

Project coverage is 88.74%. Comparing base (1affcb3) to head (9c5d246).
Report is 25 commits behind head on add-force-stop.

❗ Current head 9c5d246 differs from pull request most recent head 89b4ab1. Consider uploading reports for the commit 89b4ab1 to get more accurate results

Files Patch % Lines
src/daemon/daemon.cpp 20.00% 24 Missing ⚠️
...rc/platform/backends/qemu/qemu_virtual_machine.cpp 64.10% 14 Missing ⚠️
...tform/backends/libvirt/libvirt_virtual_machine.cpp 40.90% 13 Missing ⚠️
src/platform/backends/lxd/lxd_virtual_machine.cpp 95.45% 1 Missing ⚠️
Additional details and impacted files
@@                Coverage Diff                 @@
##           add-force-stop    #3483      +/-   ##
==================================================
- Coverage           88.89%   88.74%   -0.16%     
==================================================
  Files                 254      254              
  Lines               14081    14149      +68     
==================================================
+ Hits                12517    12556      +39     
- Misses               1564     1593      +29     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@townsend2010 townsend2010 linked an issue Apr 24, 2024 that may be closed by this pull request
@townsend2010 townsend2010 force-pushed the add-force-stop branch 2 times, most recently from 1861b89 to 36b6601 Compare May 5, 2024 13:56
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.

Need a "stopping" state for instances
4 participants