qemu-stable
[Top][All Lists]
Advanced

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

Re: [Qemu-stable] [PATCH] blockjob: expose error string via query


From: Eric Blake
Subject: Re: [Qemu-stable] [PATCH] blockjob: expose error string via query
Date: Tue, 8 May 2018 19:53:18 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0

On 05/08/2018 06:36 PM, John Snow wrote:
When we've reached the concluded state, we need to expose the error
state if applicable. Add the new field.

This should be sufficient for determining if a job completed
successfully or not after concluding; if we want to discriminate
based on how it failed more mechanically, we can always add an
explicit return code enumeration later.

I didn't bother to make it only show up if we are in the concluded
state; I don't think it's necessary.

Signed-off-by: John Snow <address@hidden>
---
  blockjob.c           | 2 ++
  qapi/block-core.json | 6 +++++-
  2 files changed, 7 insertions(+), 1 deletion(-)


+++ b/qapi/block-core.json
@@ -1172,6 +1172,9 @@
  # @auto-dismiss: Job will dismiss itself when CONCLUDED, moving to the NULL
  #                state and disappearing from the query list. (since 2.12)
  #
+# @error: Error information if the job did not complete successfully.
+#         Not set if the job completed successfully. (since 2.12.1)
+#
  # Since: 1.1
  ##
  { 'struct': 'BlockJobInfo',
@@ -1179,7 +1182,8 @@
             'offset': 'int', 'busy': 'bool', 'paused': 'bool', 'speed': 'int',
             'io-status': 'BlockDeviceIoStatus', 'ready': 'bool',
             'status': 'BlockJobStatus',
-           'auto-finalize': 'bool', 'auto-dismiss': 'bool' } }
+           'auto-finalize': 'bool', 'auto-dismiss': 'bool',
+           '*error': 'str' } }

Yep, definitely material for the stable branch.

Reviewed-by: Eric Blake <address@hidden>

--
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org



reply via email to

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