[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v6 11/14] block/backup: support block job transa
From: |
Eric Blake |
Subject: |
Re: [Qemu-devel] [PATCH v6 11/14] block/backup: support block job transactions |
Date: |
Tue, 15 Sep 2015 08:43:38 -0600 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.2.0 |
On 09/15/2015 12:11 AM, Fam Zheng wrote:
> From: Stefan Hajnoczi <address@hidden>
>
> Join the transaction when the 'transactional-cancel' QMP argument is
> true.
>
> This ensures that the sync bitmap is not thrown away if another block
> job in the transaction is cancelled or fails. This is critical so
> incremental backup with multiple disks can be retried in case of
> cancellation/failure.
>
> Signed-off-by: Stefan Hajnoczi <address@hidden>
> Signed-off-by: Fam Zheng <address@hidden>
> ---
> block/backup.c | 25 +++++++--
> blockdev.c | 132
> +++++++++++++++++++++++++++++++++++-----------
> include/block/block_int.h | 3 +-
> qapi-schema.json | 4 +-
> qapi/block-core.json | 29 ++++++++++
> 5 files changed, 155 insertions(+), 38 deletions(-)
>
> +++ b/qapi/block-core.json
> @@ -736,6 +736,11 @@
> # default 'report' (no limitations, since this applies to
> # a different block device than @device).
> #
> +# @transactional-cancel: #optional whether failure or cancellation of other
> +# block jobs with @transactional-cancel true in the
> same
> +# transaction causes the whole group to cancel.
> +# (Since 2.5)
> +#
Spurious hunk here.
> @@ -750,6 +755,18 @@
> '*on-target-error': 'BlockdevOnError' } }
>
> ##
> +# @DriveBackupTxn
> +#
> +# @transactional-cancel: #optional whether failure or cancellation of other
> +# block jobs with @transactional-cancel true in the
> same
> +# transaction causes the whole group to cancel.
> +#
Maybe mention default false here...
> +# Since: 2.5
> +##
> +{ 'struct': 'DriveBackupTxn', 'base': 'DriveBackup',
> + 'data': {'*transactional-cancel': 'bool' } }
> +
> +##
> # @BlockdevBackup
> #
> # @device: the name of the device which should be copied.
> @@ -785,6 +802,18 @@
> '*on-target-error': 'BlockdevOnError' } }
>
> ##
> +# @BlockdevBackupTxn
> +#
> +# @transactional-cancel: #optional whether failure or cancellation of other
> +# block jobs with @transactional-cancel true in the
> same
> +# transaction causes the whole group to cancel.
and again here.
With those three fixes,
Reviewed-by: Eric Blake <address@hidden>
(and we can simplify it later when more qapi patches land)
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature
- [Qemu-devel] [PATCH v6 07/14] blockjob: Add "completed" and "ret" in BlockJob, (continued)
- [Qemu-devel] [PATCH v6 07/14] blockjob: Add "completed" and "ret" in BlockJob, Fam Zheng, 2015/09/15
- [Qemu-devel] [PATCH v6 08/14] blockjob: Simplify block_job_finish_sync, Fam Zheng, 2015/09/15
- [Qemu-devel] [PATCH v6 09/14] block: Add block job transactions, Fam Zheng, 2015/09/15
- [Qemu-devel] [PATCH v6 10/14] blockdev: make BlockJobTxn available to qmp 'transaction', Fam Zheng, 2015/09/15
- [Qemu-devel] [PATCH v6 11/14] block/backup: support block job transactions, Fam Zheng, 2015/09/15
- [Qemu-devel] [PATCH v6 12/14] iotests: 124 - transactional failure test, Fam Zheng, 2015/09/15
- [Qemu-devel] [PATCH v6 13/14] qmp-commands.hx: Update the supported 'transaction' operations, Fam Zheng, 2015/09/15
- [Qemu-devel] [PATCH v6 14/14] tests: add BlockJobTxn unit test, Fam Zheng, 2015/09/15