qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Max Reitz <mreitz@redhat.com>
To: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>,
	qemu block <qemu-block@nongnu.org>
Cc: Kevin Wolf <kwolf@redhat.com>, "Denis V. Lunev" <den@openvz.org>,
	qemu-devel <qemu-devel@nongnu.org>
Subject: Re: about mirror cancel
Date: Fri, 16 Apr 2021 09:11:11 +0200	[thread overview]
Message-ID: <ea96f574-dc36-2546-53be-ddb02ba02880@redhat.com> (raw)
In-Reply-To: <5df8166f-a204-6510-e27a-1b334f0bb3f3@redhat.com>

On 16.04.21 09:05, Max Reitz wrote:
> On 15.04.21 20:46, Vladimir Sementsov-Ogievskiy wrote:

[...]

>> Note, that if cancelling all in-flight requests on target is wrong on 
>> mirror cancel, we still don't have real bug, as the only 
>> implementation of .bdrv_cancel_in_flight is stopping reconnect waiting 
>> in nbd driver. So, we'll cancel requests only if connection is already 
>> lost anyway.
>>
>> But that probably means, that correct name of the handler would be 
>> .bdrv_cancel_in_fligth_requests_that_will_most_probably_fail_anyway()..
> 
> It’s documentation states that it should cancel all in-flight requests, 
> so it’s more likely it just isn’t implemented where it could be.

Oh, I now see you added it in the same series.  Well, then I suppose 
you’re free to change the semantics as you see fit.

But be aware that even cancelling those requests means that you abandon 
the target.  So it must then fail instead of emitting the COMPLETED 
event (AFAIR the mirror job emits COMPLETED when cancelled in READY with 
force=false).

If the user wants the mirror job to create a consistent copy and so 
cancels it after READY (with force=false), I don’t know whether 
cancelling those hanging requests is what we want.  If the cancel hangs 
and the user sees this, they are still free to decide to cancel again 
with force=true, no?

Max



  reply	other threads:[~2021-04-16  7:12 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-15 18:46 about mirror cancel Vladimir Sementsov-Ogievskiy
2021-04-16  7:05 ` Max Reitz
2021-04-16  7:11   ` Max Reitz [this message]
2021-04-16  7:45     ` Vladimir Sementsov-Ogievskiy

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ea96f574-dc36-2546-53be-ddb02ba02880@redhat.com \
    --to=mreitz@redhat.com \
    --cc=den@openvz.org \
    --cc=kwolf@redhat.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=vsementsov@virtuozzo.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).