From de253f14912e88f45dbe66984440d27221a75a60 Mon Sep 17 00:00:00 2001 From: Luiz Capitulino Date: Fri, 27 Jul 2012 16:18:16 -0300 Subject: qmp: switch to the new error format on the wire IMPORTANT: this BREAKS QMP's compatibility for the error response. This commit changes QMP's wire protocol to make use of the simpler error format introduced by previous commits. There are two important (and mostly incompatible) changes: 1. Almost all error classes have been replaced by GenericError. The only classes that are still supported for compatibility with libvirt are: CommandNotFound, DeviceNotActive, KVMMissingCap, DeviceNotFound and MigrationExpected 2. The 'data' field of the error dictionary is gone As an example, an error response like: { "error": { "class": "DeviceNotRemovable", "data": { "device": "virtio0" }, "desc": "Device 'virtio0' is not removable" } } Will now be emitted as: { "error": { "class": "GenericError", "desc": "Device 'virtio0' is not removable" } } Signed-off-by: Luiz Capitulino Reviewed-by: Markus Armbruster --- qmp-commands.hx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'qmp-commands.hx') diff --git a/qmp-commands.hx b/qmp-commands.hx index ac46638..e07c7b0 100644 --- a/qmp-commands.hx +++ b/qmp-commands.hx @@ -435,8 +435,8 @@ Example: -> { "execute": "inject-nmi" } <- { "return": {} } -Note: inject-nmi is only supported for x86 guest currently, it will - returns "Unsupported" error for non-x86 guest. +Note: inject-nmi fails when the guest doesn't support injecting. + Currently, only x86 guests do. EQMP -- cgit v1.1