From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:43981) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZWnnF-0008UE-57 for qemu-devel@nongnu.org; Tue, 01 Sep 2015 11:48:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZWnnA-0004KU-PO for qemu-devel@nongnu.org; Tue, 01 Sep 2015 11:48:17 -0400 Received: from mx1.redhat.com ([209.132.183.28]:37829) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZWnnA-0004KB-HM for qemu-devel@nongnu.org; Tue, 01 Sep 2015 11:48:12 -0400 References: <1438703896-12553-1-git-send-email-armbru@redhat.com> <1438703896-12553-31-git-send-email-armbru@redhat.com> <55C27001.1050307@redhat.com> <87pp31hr5i.fsf@blackfin.pond.sub.org> <877foa9thi.fsf@blackfin.pond.sub.org> From: Eric Blake Message-ID: <55E5C8B6.10302@redhat.com> Date: Tue, 1 Sep 2015 09:48:06 -0600 MIME-Version: 1.0 In-Reply-To: <877foa9thi.fsf@blackfin.pond.sub.org> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="SgbecKi8g3qJb2EuhowAr8fs0EsdODFhW" Subject: Re: [Qemu-devel] [PATCH RFC v3 30/32] qapi: New QMP command query-schema for QMP schema introspection List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Markus Armbruster Cc: kwolf@redhat.com, berto@igalia.com, qemu-devel@nongnu.org, mdroth@linux.vnet.ibm.com This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --SgbecKi8g3qJb2EuhowAr8fs0EsdODFhW Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 09/01/2015 07:09 AM, Markus Armbruster wrote: > Markus Armbruster writes: >=20 >> Eric Blake writes: >> >>> On 08/04/2015 09:58 AM, Markus Armbruster wrote: > [...] >>>> +++ b/qapi/introspect.json >>> >>>> +{ 'struct': 'SchemaInfoObject', >>>> + 'data': { 'members': [ 'SchemaInfoObjectMember' ], >>>> + '*tag': 'str', >>>> + '*variants': [ 'SchemaInfoObjectVariant' ] } } >>> >>> I take it that either tag and variants will both be omitted, or both = be >>> present. No clean way to represent that in the schema, though. >> >> Needs a comment. >=20 > Alternatively, wrap both tag and variants in an object, mandatory there= , > then make that object optional. Doesn't feel wortwhile to me, but if > you like it better, I'll reconsider. No; the extra nesting it would create in QMP is not worth it. (Well, maybe we want to think about a qapi extension that would allow unboxed substructs, where you either get all or none of a sub-struct, but with all of the members of the substruct passed in QMP at the same nesting level as the rest of the object; but I'm not sure we need it, and it certainly is too complex to be worrying about right now while the basics aren't even in place) >>>> + def visit_enum_type(self, name, info, values): >>>> + self._gen_json(name, 'enum', { 'values': values }) >>> >>> Do you want to add a sort() on values here? >> >> I want to review the introspection schema systematically for sorting >> opportunities. >=20 > I'm going to leave this job for later, because I feel we should get the= > basics in as soon as possible. We then have the rest of the developmen= t > cycle to refine stuff. Sure; we have until 2.5 is released to bake in our final assumptions, and the sooner we can get in a baseline, the easier it will be to play with what further changes we want to make on top. --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --SgbecKi8g3qJb2EuhowAr8fs0EsdODFhW 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/ iQEcBAEBCAAGBQJV5ci2AAoJEKeha0olJ0Nq0t8H/jLQCqG9L5YL32tLEzpESlYG mFnUZn/ip/FFH61EELDA31NZ+6qU9/HQXoAUS9cVDmJu2NmXAgCH6KOMFzPyg6KO /7afKaX1glbHV71dsmZgai7xhWZYl7sqaRcD/xHCvvUwUxZPzxGGy8by6S2itdba pgim5GqPhnJd6RDEWph66m1v9flLr0o1uCVLPzKycVZY0qk0+UM2G+sESmuRjaqL zvaApCakQBLutT1m9agGmUIHX2XrW7Q5mGeCW1JqVMHStbLlDadqb3ksRj87rPjc eHdnEZzzZh+10IiBaqboPWWLB5xtRiFfhU5JG66EIciWp4fzt4Vr9Ic/fSny3IU= =u69n -----END PGP SIGNATURE----- --SgbecKi8g3qJb2EuhowAr8fs0EsdODFhW--