On Thu, Jun 27, 2013 at 12:06:44PM +0200, Paolo Bonzini wrote: > Il 27/06/2013 10:17, Stefan Hajnoczi ha scritto: > >>> > > Il 26/06/2013 05:59, Fam Zheng ha scritto: > >>> > > This leads to another observation: a sync:'none' block-backup job > >>> > > probably should never complete, and should instead go on until > >>> > > explicit > >>> > > cancellation. This is because the job does no background writes, and > >>> > > thus completion would only happen after the guest has written the > >>> > > whole > >>> > > disk. Writing the whole disk is rare enough that it will likely cause > >>> > > bugs in the clients. It is easier just to never complete the job. > >>> > > > >> > > >> > Yes, the sync mode none will simply run forever until cancelled. > > There is a dedicated command to successfully complete a job: > > > > block-job-complete > > block-job-complete should only be called after a BLOCK_JOB_READY event, > but when would the backup job raise it? Immediately after starting? > > There is no behavioral difference in this case between cancel and > complete in fact as far as I understand, so I think cancelling the job > would match existing practice better.
Okay. Ian Main also preferred using block-job-cancel without the BLOCK_JOB_READY/block-job-complete lifecycle. Thanks for the input! Stefan