qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [RFC PATCH 13/36] block: introduce block job error


From: Eric Blake
Subject: Re: [Qemu-devel] [RFC PATCH 13/36] block: introduce block job error
Date: Fri, 15 Jun 2012 11:50:07 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:12.0) Gecko/20120430 Thunderbird/12.0.1

On 06/15/2012 09:05 AM, Paolo Bonzini wrote:
> The following behaviors are possible:
> 
> 'report': The behavior is the same as in 1.1.  An I/O error,
> respectively during a read or a write, will complete the job immediately
> with an error code.
> 
> 'ignore': An I/O error, respectively during a read or a write, will be
> ignored.  For streaming, the job will complete with an error and the
> backing file will be left in place.  For mirroring, the sector will be
> marked again as dirty and re-examined later.
> 
> 'stop': The job will be paused and the job iostatus will be set to
> failed or nospace, while the VM will keep running.  This can only be
> specified if the block device has rerror=stop and werror=stop or enospc.
> 
> 'enospc': Behaves as 'stop' for ENOSPC errors, 'report' for others.
> 
> In all cases, even for 'report', the I/O error is reported as a QMP
> event BLOCK_JOB_ERROR, with the same arguments as BLOCK_IO_ERROR.

Looks reasonable.

> +++ b/qapi-schema.json
> @@ -935,11 +935,14 @@
>  #
>  # @speed: the rate limit, bytes per second
>  #
> +# @io-status: the status of the job
> +#
>  # Since: 1.1
>  ##
>  { 'type': 'BlockJobInfo',
>    'data': {'type': 'str', 'device': 'str', 'len': 'int',
> -           'offset': 'int', 'paused': 'bool', 'speed': 'int'} }
> +           'offset': 'int', 'paused': 'bool', 'speed': 'int',
> +           'io-status': 'BlockDeviceIoStatus'} }

Again, when adding members to output-only types compared to a previous
release, should we be marking the additions as optional, as in:

'*io-status': 'BlockDeviceIoStatus'

to indicate that the member may not be present when talking to older qemu?

-- 
Eric Blake   address@hidden    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]