api: reduce overly lengthy comment

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
Thomas Lamprecht 2023-10-10 12:57:00 +02:00
parent 7ba974a682
commit 263c803dd1

View File

@ -3081,12 +3081,8 @@ __PACKAGE__->register_method({
my $shutdown = 1; my $shutdown = 1;
# if vm is paused, do not shutdown (but stop if forceStop = 1) # sending a graceful shutdown command to paused VMs runs into timeouts, and even worse, when
# otherwise, we will infer a shutdown command, but run into the timeout, # the VM gets resumed later, it still gets the request delivered and powers off
# then when the vm is resumed, it will instantly shutdown
#
# checking the qmp status here to get feedback to the gui/cli/api
# and the status query should not take too long
if (PVE::QemuServer::vm_is_paused($vmid)) { if (PVE::QemuServer::vm_is_paused($vmid)) {
if ($param->{forceStop}) { if ($param->{forceStop}) {
warn "VM is paused - stop instead of shutdown\n"; warn "VM is paused - stop instead of shutdown\n";