From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50492) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZWQg0-0006ZQ-AA for qemu-devel@nongnu.org; Mon, 31 Aug 2015 11:07:25 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZWQfv-0007HU-0T for qemu-devel@nongnu.org; Mon, 31 Aug 2015 11:07:16 -0400 Received: from mx1.redhat.com ([209.132.183.28]:42839) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZWQfu-0007Gj-Gz for qemu-devel@nongnu.org; Mon, 31 Aug 2015 11:07:10 -0400 References: <1438159544-6224-1-git-send-email-zhang.zhanghailiang@huawei.com> <1438159544-6224-20-git-send-email-zhang.zhanghailiang@huawei.com> <55E0DCFB.2070402@redhat.com> <55E41E1D.7020500@huawei.com> From: Eric Blake Message-ID: <55E46D9B.2040908@redhat.com> Date: Mon, 31 Aug 2015 09:07:07 -0600 MIME-Version: 1.0 In-Reply-To: <55E41E1D.7020500@huawei.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="UvcMHc5vmoeusoGEWSs3IjvXaXQn54U1a" Subject: Re: [Qemu-devel] [PATCH COLO-Frame v8 19/34] qmp event: Add event notification for COLO error List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: zhanghailiang , qemu-devel@nongnu.org Cc: lizhijian@cn.fujitsu.com, quintela@redhat.com, Markus Armbruster , yunhong.jiang@intel.com, eddie.dong@intel.com, peter.huangpeng@huawei.com, dgilbert@redhat.com, arei.gonglei@huawei.com, amit.shah@redhat.com, Michael Roth This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --UvcMHc5vmoeusoGEWSs3IjvXaXQn54U1a Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 08/31/2015 03:27 AM, zhanghailiang wrote: >>> +Data: None. >>> + >>> + - "mode": COLO mode, 'primary' or 'secondary' >>> + - "error": Error message (json-string, optional) The "Data: None" designation is inconsistent with the fact that you do provide data. >>> + >>> +Example: >>> + >>> +{"timestamp": {"seconds": 2032141960, "microseconds": 417172}, >>> + "event": "COLO_EXIT", "data": {"mode": "primary"}} >> >> It might also be useful to provide a machine-parseable parameter on >> whether the exit was due to an internal error vs. an external request.= >> Maybe by adding 'flag':'bool', since presence or absence of 'error' is= >> not as nice. >> >=20 > Good idea, but i think the type of 'flag' changes to 'str' maybe better= , > which can be 'error' or > 'request', 'bool' is not so self-explanatory. > The original reason for adding 'error' member is to help > users to know what exactly happen, but it seems to be difficult to=20 > exactly class all errors, > so i will remove it. Keeping an optional 'error' for human consumption is not bad; it's just that it is also nice to provide something for machine consumption (and we typically document that machines should NOT parse 'error' messages). --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --UvcMHc5vmoeusoGEWSs3IjvXaXQn54U1a Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJV5G2bAAoJEKeha0olJ0NqQtEH/1VwLam+uKWr5Y41+oTDASCh 9ZXXQY1KmW3u+6gqoUNXgC0zBRTDEooYbVA+v0iaDl5sdJJAI9pu/cTWbSD0P8uA 3JjbR2qhIPmI7X1XFbZINPsghqHYPEedezj1Thgttmc/9r45xJsV2n9FkWw/jVof zYBYaAQyrfVY6IlWDw1sK95BzKdNWzHv5aevdjcPvbRSjqJGjxIFyDxe50genESD GqcMvIVd61Dc1VJitREu/x/pK5VOdMYXwTlvgI6BIOL5RHq8YxL4cTxKjyRFrCze gGlamUjBMMzi5xZ4bMH6hD/wH5RtcazM5gjLQPAF30CRE/vtomokkHPjLZE/mJE= =RXXB -----END PGP SIGNATURE----- --UvcMHc5vmoeusoGEWSs3IjvXaXQn54U1a--